The battery is locked when turned clockwise. Unlocked when turned counterclockwise.
Tip for removing battery: Starting from the locked position, turn the key 90 degrees to go horizontal. Pull on the key to remove the battery.
My preferred method is to unlock the battery completely (turn counterclockwise until stop) and use pliers to pull the battery out.
Make a note that the battery can be pushed in too far and the lock mechanism actually retains it into proper position. It has to be flush with the green line seen in the picture below.