Lecturers can opt to automatically create groups in their modules. This option will form student groups by allocating members randomly or alphabetically.
You can quickly enrol participants on groups or edit their group membership from the Participants lLst.
This screencast demonstrates how to create groups in Moodle.