The reason why employers would be willing to institute flextime programs is that those programs can make their businesses more profitable. In other words, the employers create these programs for solid business reasons, not for charitable purposes.
As you point out, employees certainly like flextime programs. The fact that employees like them is one reason for businesses to implement them. Happy employees are beneficial for two reasons. First, they can be much more productive than unhappy workers. Second, they are more likely to stay in their jobs than unhappy workers are. Increasing productivity is, of course, a way of increasing profit. Reducing turnover in the workforce is also good because it reduces the costs associated with finding and training new workers.
Proponents of flextime also argue that it can give employers more flexibility as well. It can allow them to have more workers available in busy periods and fewer at times when there is less to do. It can also allow them, perhaps, to do more work without having to expand their physical plant since not all workers will be at work at the same time.
In these ways, flextime is seen as a way to make businesses themselves work better. It is, then, a clear benefit to employers no less than it is to employees.