The third of the Rambam's principles teaches: "G-d does not have a body. Physical concepts do not apply to Him. There is nothing whatsoever that resembles Him at all."
In the Torah God speaks. What we normally understand the word "speak" to mean is to communicate by means of the vocal cords. According to the third principle, God has no vocal cords, so how does He produce speach?
Medieval Jewish thinkers (Saadiah Gaon, Abraham Ibn Ezra) recognized this problem. They decided that the "voice of G-d" was not actually a voice, but a sound specifically created by Him for the purpose of communicating with his prophets. He created trees, for example, and when needed He also creates voice-like sounds.
A similar, but more difficult quetsion is this: In what sense does God think?
The brain is the source of mental life; our consciousness, emotions, and will are the products of neural processes. Thinking involves the brain. And if thoughts are the product of those coils of grey matter contained within our skulls --just as surely as voices are the product of vocal cords-- in what sense are they experienced by an incorpreal being?