In a Moodle course, you can add students to a group. Then, you can manage that group's access to activities and resources in the course instead of managing the students one at a time. Moodle also enables you to create site-wide groups. These are called cohorts.
The cohorts sync enrollment method enables you to enroll a cohort into a course. This enrolls everyone in that cohort in one go.