There are fish for a 5 gallon but not cichlids like Rams or Apistos. You need to be thinking of nano fish like Chilli Rasboras or possibly very small Badis species like Black Tiger Badis - both assuming you have soft water.
A single pair of Apistogramma need a 24 inch tank minimum, though I did better with 30 inch front glass tanks. A small adult male can reach 4 inches in many species, and a 5.5 is 16 inches across, and 8 front to back. It can't move - like being a human in a 6x3 room. Rams are smaller, but much more sensitive to water conditions than moist available Apistos.