A prison guard who tattooed her convict lover’s nickname on her neck and had sex with him in a prayer room has been jailed.