Traditional carriers break even or even take a small loss on a percentage of deliveries because it's important to their business model to have consistent prices and deliver everywhere. Amazon isn't restricted that way, they can cherry pick which places they deliver based on how profitable it is to get the package to the doorstep.
Essentially Amazon is draining away all the deliveries which made UPS/ USPS/ FedEx profitable. How sustainable this model is long term is somewhat questionable.