This is explained in the PHB, page 198:
Knocking a Creature Out
Sometimes an attacker wants to incapacitate a foe, rather than deal a killing blow. When an attacker reduces a creature to 0 hit points with a melee attack, the attacker can knock the creature out. The attacker can make this choice the instant the damage is dealt. The creature falls unconscious and is stable.
You don't need a bludgeoning weapon or any special die roll. All the PCs need to do is declare they would like to knock the creature out instead of killing it when it hits 0 HP.