Mutual fund was first created back in 1924, 5 years prior to the worst stock market crash (so far) in history. The idea was truly ingenuous- collect the money from investors, invest them in all kinds of securities, and issue the mutual fund shares to those investors in exchange for their money. What securities the investors' money will be invested into is entirely up to the management team of the mutual fund.
The upside of this idea was that all of a sudden, the average investor gained access to the very broad spectrum of securities-stocks, bonds, real estate etc., and all for a relatively small initial investment. Before this invention, you've got to buy individual securities to achieve diversification of this kind.
Now, the downside: the expenses. In an actively managed mutual fund, the expense ratio (percentage of the money under management that is deducted each year) can be as high as 2% annually (we're talking about mutual funds bought outside retirement vehicles like 401k, where you can find even more "expensive" funds). It means that no matter whether your investment goes up or goes down in price, you've got to keep paying these percentages to the mutual fund company. Billions of dollars each year are collected that way from investors.
How do they use all these money collected from investors? At least 70% of it goes toward managers’ salaries.