I don't know what you did to get yourself into jail, as you say again. Obviously your wife does not want a relationship with you- so you have to abide by her wishes. You have to let go and move on. You will get yourself into more trouble if you don't. If it was meant to be,then she will find you- otherwise you need to keep yourself busy fixing whatever it is you did to get yourself into this situation.
If you are truly sorry for the pain you have caused other people you will find a way to correct what damage you can.
I can pray you will turn this around and make amends- IMO- that is the only hope you have. I hope you can make what sounds like a bad situation a turning point for yourself. Good luck.