If at the point at which the worlds were created some sort of primordial matter had already existed, and Hashem merely altered its form such that the worlds had come to exist from that matter, then that change of state would have to be categorized as “yesh mi’yesh”—“something from something.” When we say that He created the world “something from nothing,” we mean that the world’s existence began at one point, and was preceded by total non-existence.
However, this requires explanation, for Hashem surely did not create the world by accident, G–d forbid. Thus, He must have created it with conscious intent. This intent is referred to as “alos haratzon,” “The emergence of Hashem’s will.”
Before a person can embark upon a certain course of action, he has to think about doing it. The thought thus precedes the action, contains the entire plan for it, and motivates him to do it physically. This concept is expressed succinctly in reference to Hashem in the liturgical phrase, “The final action was first in thought” (Lecha Dodi hymn).
If so, in that sense the worlds already existed to some significant extent, on some level, before they were actually created. So how can we speak of the creation as having resulted from absolute nothingness?
The answer is simple. Indeed, the spiritual worlds existed in Hashem’s will before they were created. However, on that level they existed in a state of total submission and selflessness. They were not a “something” at all. By definition, creation entails producing a realm that is a “yesh,” i.e., it is fundamentally self-aware and feels itself to be an independent entity from Hashem. This feeling of independence did not exist at all in the worlds as they exist on the level of Hashem’s will to create the worlds, for there everything is nullified to Hashem and feels no independent existence. Thus, the worlds can truly be said to have been created from absolute nothingness.
Sefer HaMa’amarim 5664, p. 4.