Due to their size, one might think of the mushrooms as spaceborne cities, with the Starfleet affairs a minor side business at the basement level. If so, one might then decide the mushrooms are to be found next to worlds that are not particularly well established colonies - either surface conditions force the people to make the effort of living in space, or then the space city precedes the effort of colonizing the planet.
However, Earth does have one of those in medium orbit, even if it's merely an early half-size version of the later SB74 type. Does this disprove the idea of the station type being associated with poorly developed worlds? Not necessarily, as Earth's vicinity would simply be the testbed of technologies and strategies to be utilized in deep space.
Whichever the "reality", it does seem that those structures serve other purposes besides Starfleet base functions. Incidentally, only SB74 was ever mentioned to be involved in starship repair, and even then only in internal shirtsleeves work such as computer upgrading. The other bases were not said or shown to repair starships, let alone construct them, nor did we see equipment that would have allowed for such things.
Thus, the starship-handling part of the mushrooms is IMHO a better analogy to an international airport than to a busy naval yard. It handles the other needs of visiting starships besides maintenance, repair and overhaul: it caters for the passengers and crews, it moves around the luggage and cargo, and it may supply the fuel and consumables and fresh lemon-scented towelettes. And it processes the arriving passengers forward to the space city part or to the planet down below, and does the reverse to the departees.
Timo Saloniemi