Ditto for legislative solutions. There's too much conflict of interest, susceptibility to lobbying, non-representation of marginalized groups or those who would be doctors but are not because of troubling practices, etc.
From Mises.org[0]
To accomplish the twin goals of artificially elevated incomes and worship by patients, AMA formulated a two-pronged strategy for the labor market for physicians. First, use the coercive power of the state to limit the practices of physician competitors such as homeopaths, pharmacists, midwives, nurses, and later, chiropractors. Second, significantly restrict entrance to the profession by restricting the number of approved medical schools in operation and thus the number of students admitted to those approved schools yearly.
AMA created its Council on Medical Education in 1904 with the goal of shutting down more than half of all medical schools in existence. (This is the Council having its 100th anniversary celebrated in Chicago this weekend.) In six years the Council managed to close down 35 schools and its secretary N.P. Colwell engineered what came to be known as the Flexner Report of 1910. The Report was supposedly written by Abraham Flexner, the former owner of a bankrupt prep school who was neither a doctor nor a recognized authority on medical education. Years later Flexner admitted that he knew little about medicine or how to differentiate between different qualities of medical education. Regardless, state medical boards used the Report as a basis for closing 25 medical schools in three years and reducing the number of students by 50% at remaining schools.
The article is thoroughly footnoted. One might take exception with specifics, but it seems hard to argue that the above is not approximately correct.[0]: https://mises.org/library/100-years-medical-robbery
Edit: I see the downvotes, but don't see the justification. I know Mises is an often-unpopular resources, but the above article is well-researched. If there are problems with the line of reasoning, I'd love to hear your perspective on it.