Mikkke, to be honest, I don't envy you, your brother or his family for being in the situation that you have found yourselves to be in. There are so many issues and necessary adjustments to be made.
Sexuality is a very complex part of our human realities and to make matters worse, it varies from person to person. For example, sex can often times be used as a means of "acting out" or bringing one's anxiety or frustration to expression. This needs to be considered when looking at your brother's choices or activity whilst in prison.
Bisexuality comes in about 13 different forms. One of these forms is what's called "Circumstantial Bisexuality". In this case, the person is predominantly heterosexual, but will choose same sex partners only in situations where there is no access to other-sex partners.
In all honesty though, only your brother will really know what prompted him to opt to have same-sex relations and just how much it meant to him. The fact that he has the freedom to express as much as he has already reveals a great deal about the kind of relationship that you share and that you make it possible for him to encounter a place of safety and acceptance through confiding in you. Is there any greater gift than what you are already offering him? The magnitude of his sharing and the risk involved is a great compliment offered to you. I hope that you are aware of it.
Taking this and all of the adjustment that all of you are yet to have to make into account, the only advice that I can offer you is to allow him to be. Yes, it certainly will be difficult and the mere fact that you made this post tells me that you love and care about him very deeply. Unfortunately though, you really aren't able to live his life for him and make the necessary choices for him. (I hope that you don't read into this statement too deeply). What I'm trying to say, is that in the midst of all the adjusting, your brother has a lot of hard decisions to make about his future (and his wife along with him). Being able to make the right decisions will mean a great deal to him but even more so if he knew that it all came from him.
The best that you can do for him is to remind him of your love, care and support because through doing so, he knows that he will have you to fall back on...and at times his choosing to turn to you to confide in or to ask for advice will be the best possible choice for him to make. Experience has shown me just how difficult it is to do, but I assure you that most times the best way to love someone is to stand back and allow them to bump their heads (should things play out that way) and to then jump in and help them to pick up the pieces.
I wish both you and your brother all of the very best.