Capitalism is not the same thing as a free market. A free market means all transactions are voluntary. That's how wealth gets built--by voluntary cooperation among productive people through specialization and trade.
Capitalism is just the view that one should try to accumulate more capital, by hook or by crook. And there are lots of ways to do that that don't involve any kind of productive work, much less building wealth through cooperation, specialization, and trade. Buying government favors, for example, which is how most big-time "capitalists" in US history did it (for example, the railroad barons who got the government to give them exclusive access to key routes). Today they do it by buying regulations that favor them.