When I was reading this post, it was mentioned that a field $k$ is an initial object in the category of $k$-algebras. But if I understand things correctly, this seems to rely on some (rather reasonable) convention.
A $k$-algebra is simply a ring morphism with domain $k$, so saying that $k$ is an $k$-algebra amounts to an endomorphism $k \to k$ (aka the structure map). But it seems to me that in the category of $k$-algebras (i.e. the coslice category $k/\mathbf{Ring}$), $k$ need not be initial if the $k$-algebra structure map on $k$ is not an automorphism. So when regarding $k$ as an $k$-algebra without any mention of the algebra structure, is it a common convention to take the identity map for the structure map?
The question might seem trivial to someone, but I'm still an absolute beginner in $R$-algebra.