Castle Oblivion
Castle Oblivion is the setting of Kingdom Hearts: Chain of Memories, and the only world the characters actually visit. It is controlled by Marluxia of Organization XIII. There are thirteen above ground floors, and 12 basements.
Organization Headquarters
The origins of Castle Oblivion and its' use prior to the series are still unknown other than it exists in a dimension in between light and darkness, similar to Twilight Town. However, it was eventually found by Xemnas, Superior of Organization XIII, who decided to convert it to a base of operations for the Organization. The fortress soon became a base where research and experiments would be performed on memories. Since the members of Organization XIII lack emotions, they need to rely on memories to piece together their characterizations and make them remember how to injure or influence a heart.
Xemnas sent Xigbar and Xaldin to recruit more members, as they needed a good number in order to run the fortress. Eventually, a girl named Namine was created in this castle and was found by the organization. They soon learned of her strange abilities on memories and she became the core of the research. To further help, Xemnas had pods created that could piece together memories to aid in the research. The castle and Namine were eventually trusted to Marluxia, a new member. However, Marluxia would use this grant in power in a plot to seize control over the Organization.
A Separate Motive
While Xemnas did want to experiment of memories in the Castle, it is largely hinted that he had a separate motive. This motive was brought up in a conversation between Xigbar and Zexion. Xigbar believes that Xemnas is searching for a called the Room of Awakening and believes that Xemnas thinks it’s somewhere in Castle Oblivion. Xemnas, when he was known as Xehanort, constructed a Room called The Room of Sleep and houses armor that Xemnas refers to as “Friend”. The Room of Awakening was not made by Xehanort, but does appear to exist and may house another friend. Xemnas’s plans for this room are unknown.
In Chain of Memories
Sora, Donald, and Goofy follow Pluto into Castle Oblivion. As soon as they enter, they forget all their skills, and are forced to use the castle's card-based combat system. The higher they progress up the Castle, the more memories are reshaped by Namine. This is so that Marluxia and Larxene can use Sora as a puppet to overthrow Xemnas. The scheme fails thanks to Axel, and Marluxia and Larxene are killed.
Reverse/Rebirth Mode
Riku awakens inside the lowest basement of Castle Oblivion, as a result of his connection to Sora. Here he faces his memories of both Xehanort's Heartless and Maleficent, and overcoming his fear of the darkness within himself. It was within the Castle that he meets DiZ and Namine, as well as reuniting with King Mickey.