For a many-electron atom, the angular momentum operators (orbital and spin) of the individual electrons do not commute with the Hamiltonian, but their sum does.
Consider an atom with two electrons, which we will call (1) and (2):
$\hat{\vec{l}}_1$, is the operator of the orbital angular momentum of the electron (1).
$\hat{\vec{l}}_2$, is the operator of the orbital angular momentum of the electron (2).
$\hat{\vec{L}}=\hat{\vec{l}}_1+\hat{\vec{l}}_2$, is the operator of the total angular momentum of the atom.

The total orbital angular momentum of the many-electron atom has two associated operators that commute with each other and with the Hamiltonian, $\hat{L}^2$ and $\hat{L}_z$, which allows us to simultaneously know the angular momentum at square, its Z component and the energy of the atom.
The measure of the physical observable associated with $\hat{L}^2$, gives us $\hbar^2L(L+1)$, where L is the quantum number of the orbital angular momentum. This quantum number is obtained by adding the quantum numbers of the orbital angular momentum of each electron, that is: \begin{equation} L=l_1\otimes l_2=l_1+l_2, l_1+l_2-1......... .|l_1-l_2| \end{equation} In the language of group theory, the coupling between two angular momenta is equal to the direct product of their representations, $l_1\otimes l_2$.
The measure of the physical observable associated with the operator $\hat{L}_z$, gives us $M_L\hbar$, where $M_L$ is the quantum number of the total orbital angular momentum in the Z direction. Said quantum number is obtained as the sum of the angular momentum quantum numbers of individual electrons. \begin{equation} M_L=m_{l1}+m_{l2} \end{equation} We proceed analogously with the angular momentum of spin for the many-electron atom. Only the letter L should be replaced by S, both in the operators and in the quantum numbers.