If you dont know the rules to rugby, it might seems chaotic and hard to follow. If you get familair with the rules, you will find out rugbyplayers are managed by strict rules and regulations. World Rugby has these rules clearly outlined on their website: Rules.
Because rugby can be quite complicated to follow, a lot of clips and films have been made to explain it to you. Below are two youtube clips explaning the game. They will introduce you to the basics of rugby.