There is actually a law that requires FedEx and UPS to charge more for some parcels ( https://pe.usps.com/text/qsg300/Q608.htm ). It was created after Lysander Spooner created the American Letter Mail Company ( https://en.wikipedia.org/wiki/American_Letter_Mail_Company ) and delivered mail between large cities for 10% of the cost of the US post office.
The argument is always that a private mail company would deliver mail to the cheapest places first (like the American Letter Mail Company did) and the US post office would get stuck with the unprofitable mail. But that could be addressed by just requiring any mail company to deliver to all addresses. Instead we have a law that just requires companies charge more than the post office.