Nunnery was Elizabethan slang for a brothel. He was not telling Ophelia to go and take up in a religious order.Doesn’t mean he was or was not a crypto-Catholic. Just that it’s not exactly evidence he was.
But there were no nunneries in England for the 100 years before shake a spear wrote this, and hardly any for the next 100.
Ergo, purgatory was Elizabethan slang for a pub.
“Kingdom” was slang for a house.
“Horse” was slang for a prostitute.
ergo, My kingdom for a horse.
Every word in Shake a sprrearespeare is slang.