It depends on where they are incarcerated and how long their sentence is. Usually, inmates with short sentences are not permitted to marry while locked up.
https://www.inmateaid.com/ask-the-inmate/can-me-and-my-inmate-get-married-while-he-s-in-jail#answer
Accepted Answer Date Created: April 15,2016