Why fundamental groups are defined only for loops- better explained than in Munkres’ Topology.

I want to point out why fundamental groups are defined for loops, and not path homotopy classes. This is something that Munkres’ Topology does not do a good job of explaining.

Munkres says that we cannot define groups on path homotopy classes because for some pair $[f]$ and $[g]$, $[f*g]$ may not be defined. This is because it is possible that $f(1)\neq g(0)$.

This seems like a bit of an arbitrary requirement to me. Although one can clearly see the benefits of defining $[f]*[g]$ only when $f(1)=g(0)$, this can be worked around. For starters, if the path homotopy class between $f(1)$ and $g(0)$ is $[h]$, one could define $[f]*[g]$ as $[f*h*g]$. Obviously this would require the axiom of choice if there are multiple path homotopy classes between $f(1)$ and $g(0)$, but I still think this can be worked around.

The reason why fundamental groups are defined for loops is that there is a unique identity and inverse for every element (path homotopy class). For example, if $f$ is a path from $x_1$ to $x_2$, then $[e_{x_1}]*[f]=[f]*[e_{x_2}]=[f]$. Clearly $[e_{x_1}]\neq[e_{x_2}]$. However for a loop, the identity is unique- namely $[e_{x_0}]$, where $x_0$ is the point where the oop starts and ends.

The same argument works for inverses.