The market, not government, should decide the fate of these institutions
If society advances and gender becomes more irrelevant, it is likely fewer people will choose these schools, and then they will naturally disappear.
The market for education is made less competitive if schools are allowed to restrict entry on the basis of gender (or any other characteristic) because there are less sellers in the market. It reduces school choice because, with single sex schools, parents don't have the choice of sending their children to single-sex schools for the opposite sex, whereas if all schools are co-ed, then parents can send their children to any school without limitation.
Crucial social elements like education should not be left only and unregulated to the market.