I fully understand that this is a very specific question, but I got curious while watching Lockpicking Lawyer because I don't think he's picked a medieval cell door lock.
At this time they would all be what's called warded locks. An example is here
The blade of the key would engage a notch in a bar, rotating the key would move the bar aside and open the door. In the simplest form of the lock, an L-shaped tool could be inserted and rotated to do the same thing. To prevent this, the lock would have obstructions: there could be a pin in the middle of the keyhole, requiring the key to have a hollow shaft ( as you see here). The keyhole could be an odd shape, like an S or W, which the blade of the key would have to match. And within the lock would be wards, strips of metal that matched slots in the key- and you can see in the example that there are only a couple of slots on the key, so only a couple of wards. On a very expensive lock there might be many wards. But it would still be easier to pick a warded lock than a modern "Bramah" lock , that has a jagged-edge key that raises and lowers pins in a cylinder.
To foil lockpicks, locksmiths made the Provost or "thief-taker" lock in the l8th c.. It resembles a normal door lock, but messing around with a lock pick triggers the jaws to whip out from behind the decorative molding, possibly grabbing the thief but in any case blocking the lock from further tampering. As the many decorative piercings on the jaws show, this was not an inexpensive lock. A jail would have had something far simpler.