Here's why:
* "What" acts as an interrogative pronoun, asking for a specific type of cake.
* "Cake" is the noun that the pronoun modifies.
Together, they function as a noun phrase that is the subject of a sentence (e.g., "What cake did you bake?").