In my abstract algebra textbook, when introducing category it says that morphisms should satisfy several properties and two of them are:
For every object $A$ of $C$, there exists (at least) one morphism $1_A \in \text{Hom}_C(A,A)$, the ‘identity’ on A.
and
The identity morphisms are identities with respect to composition: that is, for all $f \in\text{Hom}_C(A,B)$ we have $$f1_A = f,\quad 1_Bf = f.$$
Why is it important to point out the second property? Could there be an identity that doesn't satisfy the second property?
A morphism whose domain coincides with the codomain is called an 'endomorphism'.
The first statement in itself only asserts that for every object $A$ there is an endomorphism $A\to A$. (How we call or denote this distinguished endomorphism has no strict meaning until the second statement.)
Together with the second statement, they assert that there exists such an endomorphism which acts like an identity from both sides. Hence the name and notation.
For example, in the category of sets, exactly the identity functions satisfy the second statement, and thus, any set with at least two elements has other endomorphisms, too.