Recruiting from your prisoners works like this:
It creates a random number between -2 and 12, if it's higher than your persuasion skill the prisoners declines, otherwise one whole group of them agrees. I don't know how it is determined which group agrees to join you.
About midnight the program sees if troops of that recruited type in your party run away.
- If you don't have troops of that type (advanced them or put them in a garrison) nothing happens
- If you have troops of that type a number of them are checked if they run away, the program does not check if these are the former prisoners or some other troops you acquired.
So if you put all troops of that type into a garrison you won't loose any. If you manage to upgrade them that works too.