I am struggling to better understand the language of a basic proof in abstract algebra, namely that groups have a unique identity. The proof is presented as follows: Let $G$ be a group and $a,b \in G$ be identity elements. Because $a$ is an identity, $ab=b$. Because $b$ is an identity, $ab=a$. This implies $a=b$. Therefore, since any two identities are equal, there is only one identity in $G$.
I think I can understand the fundamental fact of the proof, but not according to the language above. I have to use a proof of contradiction: Assume $G$ has two different identities. Then the expression $ab$ maps to two different elements, which is impossible. Therefore, $G$ can have only one identity.
I am wondering if anyone has suggestions regarding how to bridge the gap between my current understanding of the proof and an understanding that makes use of the language in the "official" proof.