The fictional continent containing Mordor, Gondor, and the Shire in Tolkien’s legendarium is Middle-earth.
Middle-earth is the setting for The Hobbit and The Lord of the Rings and is part of Tolkien’s larger world of Arda. It contains many regions and peoples, including the Shire in the northwest, Gondor farther south, and Mordor east of Gondor. The War of the Ring moves across several of these lands.
The name does not mean that Middle-earth is a planet or the exact center of a modern globe. Tolkien adapted the term from older Germanic and English expressions for the inhabited world. Within the mythology, Middle-earth is a region of Arda during a particular stage of the world’s history.
Aman is the realm across the sea associated with the Valar and the Undying Lands. Beleriand is a western region important to the First Age, while Númenor is an island kingdom that later sinks beneath the sea. These places belong to Tolkien’s world but are not the answer.