It is either a pr breeding or two males displaying to each other. The males usually have more colour on their body & fins, a bit of black and red.
Two males will swim side by side with their fins flared trying to show off to each other and impress the female.
A male/female pr will do a similar thing but swim near plants and occasionally stop near the plants for a few seconds, shake for a moment and then swim off. The stopping near the plants and shaking is them releasing their eggs & sperm. If you look closely you can sometimes see tiny little clear balls floating down immediately after they shake.