In the short run amazon makes more money (commission on the sale) but in the long run this hurts Amazon's brand.
I manage an amazon business account where this is a particularly bad issue because buyers are not spending their own money. They will literally spend $500 on something that is $50, because they like Amazon's reliability around delivery, the purchasing is very smooth, returns are smooth etc. I feel like they cracked down on this maybe 4-5 years ago? But still stuff slips through.
So yes, I very much like that they don't allow sellers to mark up crazily on Amazon's site.