In Alice’s Adventures Underground and in Alice’s Adventures in Wonderland a large Alice finds the golden key on the glass three-legged table, she then opens the tiny door to the garden with this key. Alice then finds that she cannot go through the tiny door due to her size, yet when she becomes small enough to go through the door and access the garden, she finds it locked. Therefore, who locked the tiny door to the garden or did it somehow close on its own?
Carroll was a very logical and controlled person, and it seems that it was exactly details like the above discrepancy - regarding who relocked the door or how did the door become locked again - that really bothered him. When he wrote his abridged version of the Alice in the hall of doors episode in The Nursery Alice, he set out to explain exactly how the door came to be locked again and who did the locking. Here is how Carroll proceeds to retell what must have been for him, up to that point, an illogical and vexing part of Alice in the hall of doors, in The Nursery Alice:
...after a little while she came to a little table, all made of glass, with three legs...and on the table was a little key: and she went round the hall and tried if she could unlock any of the doors with it. Poor Alice! The key wouldn’t unlock any of the doors. But at last she came upon a tiny little door: and oh, how glad she was, when she found the key would fit it! So she unlocked the tiny little door, and she stooped down and looked through it, and what do you think she saw? Oh, such a beautiful garden! And she did so long to go into it! But the door was far too small... So poor little Alice locked up the door, and took the key back to the table again... (p. 6).
It seems that Carroll wanted to make doubly sure that the reader understood who had relocked the door. As the Nursery Alice makes herself small enough to attempt to get through the door and into the garden, she finds that:
...when she got there, the door was locked, and the key was on the top of the table, and she couldn’t reach it! Wasn’t it a pity she had locked up the door again?
Therefore, it was Alice herself, in this new retelling of the story in The Nursery Alice, who relocks the door, and by doing so she locks herself out of the garden. It was in this way that Carroll could finally set right this one inconsistency in both Underground and Wonderland.