I need a vibrating plate compactor once in 10 years, and Home Depot has a stream of customers who need it all the time. I could buy it and rent it to others when I am not using it, but I have other things I want to do with my time. Therefore, it is profitable for Home Depot to rent it to me, and for me to pay a slight premium to never have to worry about it outside the few hours I needed to use it.
Similarly, I have rented apartments in my 20s in places I had no intention of setting down, and buying would have been a waste of time and effort.