When a person of great magical power breaks the rules, you can’t just throw them in the pokey with the cattle rustlers and meth dealers. Imprisoning someone with the ability to fly, teleport, and otherwise bend the rules of reality takes a place like the Silent Vaults.
Enclosed in an antimagic ward generated by a powerful device (in the dungeon, left side), the Vaults nullify the abilities of those contained within. The facility also has a guard barracks, warden’s residence and a chapel that is definitely not dedicated to Mystra.
Floating above the prison is a tiny island with a heavily-warded containment vault, designed to hold a person or entity of incredible arcane power. If you need to make a demon or an archlich sit and think about what they’ve done, this is the place to do it.
There’s an annotated version of this map and DM notes available to patrons.