Because regardless of how advanced we become as humanity, we still worship the most basic things such as athletic body, physical stamina, looks. Many people genuinely believe that people who are fit are better human beings than those who aren't.
I am one of the people who pay for gym membership for my runs. Here's why:
-an electronic treadmill has proper surface to run on which is easier on your legs
-it's easy to set up a phone/tablet/tv and watch whatever you want while running
-in the winter it's too cold to run outside, and in the summer it's too hot to run outside,
-random people aren't getting in your way on the pavement
-no obstacles, streets etc. that will stop you and mess up your schedule/system
-you can control the speed and height without relying on your flawed judgement, when I used to run outside I tended to slow down as I was getting tired without noticing, on a treadmill this won't happen because you input the speed and that's how fast it moves no matter what
So yeah, it is definitely worth spending money because I can do what I wanna do in a comfortable, reliable way. The convenience is well worth it. Sure you can go for a run for free, you can also bake your own bread for free, make your own burgers, build your own furniture etc. to save some money, but usually people prefer to spend some money to have it done for them. Free shit is not always better.