to fasten something with a key, or be fastened with a key
Did you lock the car?
She carefully used the key to lock the front door before leaving.
The security guard was responsible for locking the gates at night.
It's crucial to lock valuables in a safe when staying at a hotel.
Before closing the shop, the owner double-checked to ensure all doors were properly locked.