In Revelation 9:1–2, an angel is given a key to, or control over, the bottomless pit, and he uses the key to open that pit. Later, an angel is seen locking things in the bottomless pit (20:1–3).
Revelation 20
New International Version
The Thousand Years
20 And I saw an angel coming down out of heaven, having the key to the Abyss and holding in his hand a great chain. 2 He seized the dragon, that ancient serpent, who is the devil, or Satan, and bound him for a thousand years. 3 He threw him into the Abyss, and locked and sealed it over him, to keep him from deceiving the nations anymore until the thousand years were ended. After that, he must be set free for a short time