The standard collective noun is a class (e.g., “a class of students”). It can refer to students in the same course, grade, or institution.