You have your conception of profit backwards.
The existence of profit is supposed to act as an incentive to competition. Profit isn't something that is added on top of the cost; profit is the difference between the cost and what the market is willing to pay. Lots of profit attracts competition, and competition reduces the market's willingness to pay.
Normally profit arises from looking at what the market is willing to pay, then figuring out how to provide that for some cost that is lower. Profits are normally increased by decreasing costs, since increasing prices is not normally an option - the market won't pay the higher costs due to alternatives.
What stops the market functioning is irrational markets (e.g. people always want the best and won't settle for second-best, so they overpay; or they want treatment even if risks and costs due to treatment are worse than the probability adjusted costs of the thing being treated), barriers to competition (lots of regulation - for good reason), monopolies (e.g. drug patents), information inefficiencies (lack of pricing transparency so price isn't able to act like the signal it should), information asymmetries (doctors know more than the patients, who are actually paying for the healthcare), incentive misalignment (employer-provided healthcare being a big one), etc.