I think this is the part that people miss the most. When a purchasing decision is made based on something like "who has the best quality shoes in price range X", competition can occur.
When the buying decision is "will I live or die", there's not really any choice made there. Couple that with the complete lack of transparency for how much a give procedure will cost, and you've strayed so far away from a free market that it's not even recognizable.
I mean, even the hospital can't even remotely accurately tell you how much something will cost before you actually get a bill...
Folks think that removing the "profit motive" will somehow cripple the whole system, or hospitals will try to save any penny they can (spoiler alert: they already do)
This is kind of the reason the Japanese economy is stagnant and continues to fail in winning global marketshare. Businesses that are too good will fail or at least not compete with businesses that settle for being good enough.
...where "good enough" is relative to a particular level of quality and price point, of course. Otherwise there wouldn't be different markets for rich and poor people. And this mechanic helps avoid a "collapse into mediocrity" that you'd otherwise get if all goods and services were offered at a single price point.
The real problem is what you identified at the end, that healthcare isn't anything like a free market. There's no buyer mobility, no transparency as to the level of the service you're getting - heck, you don't even know how much you're going to pay in advance, unlike almost every other industry.