Rooftops are not that much land area. A few percent of a city landscape?
Further it's dangerous. Installation, maintenance become a headache and a risk.
Then, so many rooftops are not in optimal 'viewing locations'. Shaded by trees; shaded by neighboring buildings especially in a city.
It seems natural to a non-engineer to 'make electricity where you need it'. But rooftops don't scale with need, not at all. An apartment building on a lot with 3 stories or 30, same rooftop area. Terrible economics.
And electricity is fungible! Make it over there; use it over here. Almost free. Certainly cheaper than struggling to mount something delicate in the hardest place you can find.