They rent you your own customers.
Expedia and Booking.com take 15–25% commission on rooms — frequently on travelers who already searched your hotel by name, then clicked the OTA because it outranked you on Google. You paid to be introduced to people who were already looking for you.
"Book direct" only works if "direct" is findable in the first place.