Database Theory – Determine the frequency of each unique value of an attribute in a relationship

I'm trying to figure out how to use aggregate functions to solve this problem. For example, if I had the table

enrolled (student ID, course ID)
123 897
123 645
589 452
009 897

If I wanted to know the number of courses each student enrolled in, how would I do that? I thought of that number Function, but I do not know how to separate each student ID