But you're asking why funds invest in companies like that or prefer that method of compensation. Part of it is just laziness. Investing in a company or rewarding a CEO who posts big profits seems intuitively sensible and is easy to measure. It's a lot more work to do the investigation it takes to realize they're going to crash and burn and you could be the one holding the bag.
Another factor is that fund managers are often compensated using the same methods. If the fund does well in the short term then they're rewarded. The companies dedicated to short-term profits do exactly that, as long as the market doesn't factor in the long-term value before you divest. But the bonus if it works goes to the fund manager whereas the risk is to other peoples' money.
This is largely a myth. Corporate executives have an obligation to shareholders, but that obligation is not to maximize quarterly profits. Short term profit maximization at all costs is generally not in the interests of shareholders. If you have a reputation for selling a quality product you can capitalize on it in the short term by selling a junk product at quality prices and huge profit margins, but in any kind of a competitive market that opens you up to exactly what you would expect. Someone else comes in with a real quality product at the same price and you lose all your business to them.
The reason corporate executives do things like that isn't because they're satisfying their obligation to the shareholders -- they're doing quite the opposite. But they do it anyway because of how they're compensated. Big bonus at the end of the year if profits are up; no repercussions if it tanks the company by the end of the decade because by then you're working somewhere else.
It's important to make the distinction because the shareholders are the ones who have the power to do something about it. "Obligation to the shareholders" makes it sound like the shareholders are the beneficiaries, but they're just as much victims as the customers. Making that mistake is how they become the victims.