A prison is to become an institution for male convicted sex offenders only from next month - and a merger with a jail next door is also on the cards.