arty, there has been no suggestion by the OP that the child is distressed ("screaming in panic" were your words). The OP just said her granddaughter "told her about it".
green, I wouldn't call trying to prevent you falling downstairs a 'trivial' reason. In addition, I don't think stair gates were very common when we were small.
We have always left bedroom doors open. I don't know how common that is. In the house where I grew up all the door handles are out of reach to small children so even just closing the door would 'lock' them in. If 'containment' — as in putting a baby in a cot for safety, or a playpen, or fastening it into a high chair — is all that is intended, then it is not intrinsically wrong. We do not know all the reasons why the child's door is locked, nor even if it actually is being locked, just that the child has reported to her grandma that she is shut in by, in gran's words, "caring" and "protective" parents.
The longer the OP leaves before she re-posts, the more I feel this was a wind-up.