YAY for a new tank
If your tank is cycled, your fish would thrive better if you moved them all over to the 23g. That 5g is way overstocked as it is. Mollies can get at least 3 inches, plus your ottos...so you're probably pretty close to stocked with that 23g.

I don't know if your mollies are old enough to tell, but you really should keep mollies in a harem, so the males don't exhaust the females to death.
Ummm, nothing will really fit comfortably in a 5 gallon for any extended period of time except for a
betta or maybe a single honey dwarf gourami; I think you're right to use it as a
QT if you don't want a betta.