Your question is one of theology and entertains multiple mutually-exclusive-yet-coexisting answers from various D&D products. Given that each crystal sphere has their own creation myths and pantheons, we do better to not rely on campaign-specific answers, but try to look for information from meta-settings: Spelljammer and Planescape.
The one sourcebook on religions and deities in the Planescape campaign setting is On Hallowed Ground. This book makes it clear that everything on the Outer Planes is sustained by belief and that deities make use of this fact. Yet it also does not shy away from the following open-ended question/speculation (page 37):
Here's the chant ... : The Inner Planes, seat of the elements and building blocks of nature, appeared first. The Ethereal Plane came second, followed by the Prime Material Plane, where the elements combined and formed mortals. Mortals created knowledge, and knowledge formed the Astral Plane, the bridge to belief. And with the development of belief came the Outer Planes. ... since the theory implies that primes existed before the Outer Planes ... the idea isn't exactly welcomed on the Great Ring.
A similar open-ended theological speculation is presented in the Concordance of Arcane Space sourcebook of the Spelljammer boxed set (Creation of the Universe sidebar starting on page 42). The phlogiston that fills the "volume" beyond the crystal spheres and the flow is beyond the reach of the deities; priests on spelljamming vessels cannot loose contact with their gods. Six different hypotheses are put forward, one of which speculates that there are gods-of-gods which created the universe, another speculates that the shells of the crystal spheres are naturally occuring and that the deities simply occupied these spheres and lied to mortals about creating them. [You can read a summary on the Spelljammer fandom wiki.]
###In summary The answer to your question is not well-established in the lore. It is clear that belief is essential for most deities, yet it is left to each gaming table to decide the correct answer for others (or to decide whether a correct answer exists at all).