I agree with pps...given how stressful things have been and recent changes, I am not surprised he is wanting the extra comfort of you nearby!
Definitely be there for him as he works through any fears or insecurities.
His mom Locking him into his room for the night breaks trust and knowing someone will help him if he is scared, sick, needs something, ....etc.
I am so glad you are responding to his needs. At 2.5 yo, he is still a baby and needs to know you are close.
So glad you are seeking advice from the lovely folks here!
Good luck, and know the most important thing is to respond with love and compassion. Independent sleeping will return in time