Deregulated taxis had cartels, increased and varying prices depending on destination and poorer customer service. Bad enough that many countries and cities found they had to regulate.
Now, whether medallions that are separate from vehicle and driver, and thus have a value in their own right are the best way to regulate is another question entirely. In the US specific case it seems emphatically not. Quite why many US cities had such poor taxi service when other countries have managed much better is beyond me.
If you want to argue with the phrase "protect the public," that's fine. The point is that, pre-smartphones, the medallion system ensures a functioning system, a modicum of safety, no fare surprises. It was not intended to produce the _lowest possible fares_ for riders.