The Two Towers and the entire Lord of the Rings series is set in Middle-earth, a large landmass surrounded by the Sundering Sea on the planet of Arda. The plot of the novel mostly concerns the characters' arduous travel through these fantastical lands.
Merry and Pippin travel through Fangorn and then to Isengard with the Ents; Aragorn, Legolas, and Gimli run through the fields of Rohan, reunite with Gandalf, and eventually travel under duress to the battle at Helm's Deep and then to Isengard themselves; and, of course, Frodo and Samwise fretfully follow Gollum down ever-darker paths toward Mordor. The central conflict in all of these plotlines can be boiled down to the simple fact that the place where the characters want to go happens to be far away, and it will be dangerous to get there. As such, the setting becomes a fundamental plot element throughout the novel.
The following is a necessarily limited list of the settings visited in the novel, as Tolkien's affinity for maps results in a massive number of named locations. Book 3 begins in Parth Galen, a meadow above the Falls of Rauros where the Fellowship separates and Boromir dies at the hands of the Orcs. The party follows the river Anduin south toward Rohan and pass through its wide fields and rolling hills. Merry and Pippin are taken by Orcs to the north of Rohan and eventually escape into the neighboring forest of Fangorn, where they meet Treebeard and the Ents. Aragorn, Legolas, Gimli, and Gandalf travel to Edoras, the walled capital of Rohan, and visit the gilded hall of Meduseld, where they ally with Théoden. The Rohirrim then travel to Helm's Deep, a fortified citadel set into a mountain in far western Rohan. After the battle, they reunite with Merry and Pippin at Isengard, Saruman's terrible stronghold centered at the tower of Orthanc, just to the north of Helm's Deep. The book ends with Gandalf transporting Pippin, seriously ill from viewing the Palantír, back to the east to Gondor on the back of Shadowfax.
Book 4 opens with Frodo and Samwise descending the cliffs of the Emyn Muil, eastward away from Parth Galen, where they meet Sméagol. He leads the hobbits through the Marshes of the Dead toward the Black Gate of Mordor, tall and imposing. Finding it closed, they turn south to travel to Ithilien, the beautiful region in the far east of Gondor, bordering Mordor. Specifically, they are captured and taken to the hidden guardhouse of Faramir and his fellow rangers, which features a sacred pool where Frodo finds the escaped Sméagol. Passing out of Ithilien, Sméagol leads the Hobbits to the stairs of Cirith Ungol toward the tunnel that leads to Shelob's lair. The novel ends as Samwise passes at last into Mordor in pursuit of Frodo's unconscious body, stolen by Orcs.