In my experience they prefer horizontal space over vertical space.
The recommendation for keeping Pygmys communally is 5 gals per Pygmy. With only one male per tank.
Remember you will lose 4-6" of space with putting in a proper sub layer and soil bottom.
The most I would recommend is 3 in that size cage. No more. But make sure it is heavily planted and they have tons of pathways!