Fairy tales mostly happen in "once upon a time" land, which we doubt you could find on a map. However, observe:
• Exhibit A: lots of characters are kings, queens, princes, and princesses. That means the setting has some form of feudalism going on, which was historically found in European medieval society.
• Exhibit B: castles up the wazoo. Again, this is a characteristic of Europe, the place of all things old.
Despite this decidedly European atmosphere, though, most fairy tales don't happen in a specific place or time; a few mention place names, but mostly as a way to indicate the exotic or foreign.
For instance, we hear about a count from Switzerland in "The Three Languages." Man, it must've taken foreeeever to get to Switzerland before cars or planes. It must've seemed positively outlandish. Also, "The Three Black Princesses" is set in East India, which we're betting seemed super-exotic since very few Germans of the early 1800s would've had the chance to go there.
Just like some places have names, they also appear on maps (unfortunately, not maps that exist in our world). For example, in "The Raven," the protagonist learns that he must rescue a princess at the golden castle of Mount Stromberg. He meets a helpful giant who says, "I'll look it up on my map. It shows all the cities, villages, and houses." The mountain turns out to be thousands of miles away, which luckily doesn't take too long when you go by Giant Express.
Otherwise, we get to see a lot of cottages and forests. Nice places, right? They're yet another indication that the settings of most fairy tales are modeled on some imagined past because there sure aren't that many forests around anymore. And nobody today would live in a cottage unless it had WiFi. Sometimes tales are set in caves, but mostly people get rescued from those.
Come to think of it, caves and other natural spaces function to signify not-civilization, whereas cottages and castles are based on the idea of civilization. So you could divide a lot of fairy-tale settings into "civilized spaces" and "uncivilized spaces." Just for kicks.
While the fairy tales themselves have unspecified or deliberately exotic settings, the context in which the fairy tales were being told had some definite qualities. Germany was not yet Germany, but rather a collection of regions that more or less spoke German (or related dialects). Napoleon was carving up the region to his liking, leading to yet more anxiety about which places belonged to whom.
Industrialization, capitalism, and democracy were some new concepts also floating around and influencing people when the tales were being recorded and published. The French Revolution had already happened, the United States had existed for a few decades, and the Industrial Revolution was well under way. With all this newfangleness up in the air, who wouldn't want to escape to a pleasantly comfortable medieval-ish setting where wishes came true?