$\require{AMScd}$
This is basic level question, but this kind of questions usually find no answer on stackexchange.
I am trying to introduce my self to categories theory and advanced algebraic topology. I have just learnt about group and cogroup structures. My question is about cogroup structures.
An object with a group structure $(G, \mu: G \times G \to G, u: * \to G, i: G \to G)$ satisfies among the other properties the following
\begin{CD} G \times * @<{id \times *_G}<< G\\ @V{id\times u}VV @VV{id}V \\ G \times G @>{\mu }>> G \end{CD}
Here $*$ is the terminal object and $*_G$ the unique morphism to from $G$ to $*$. This is the law of neutral element.
If I have understood properly, a cogroup object should sastify the reversed diagram, i.e.
$\require{AMScd}$ \begin{CD} G \coprod * @>{id \coprod *_G}>> G\\ @A{id\coprod u}AA @AA{id}A \\ G \coprod G @<{\mu }<< G \end{CD}
Now, choose as category $\mathbf{Top.}$ and $G = (\mathbb{S}^1, 1)$ with operation $\mu: \mathbb{S}^1 \to \mathbb{S}^1 \vee \mathbb{S}^1$ that wrap the circle "half-and-half". The claim is that this is a cogroup structure on $\mathbb{S}^1$, but to me seems not.
The above diagram becomes
\begin{CD} \mathbb{S}^1 \vee * @>{id \vee *}>> \mathbb{S}^1 \\ @A{id\vee u}AA @AA{id}A \\ \mathbb{S}^1 \vee \mathbb{S}^1 @<{\mu }<< \mathbb{S}^1 \end{CD}
But $*$ in $\mathbf{Top.}$ is both initial and terminal and so $\mathbb{S}^1 \vee \mathbb{S}^1 \to \mathbb{S}^1 \vee * \to \mathbb{S}^1$ would collpse the "right circle" of $\mathbb{S}^1 \vee \mathbb{S}^1$ to the basepoint of $\mathbb{S}^1$ and so $\mathbb{S}^1 \to \mathbb{S}^1 \vee \mathbb{S}^1 \to \mathbb{S}^1 \vee * \to \mathbb{S}^1$ would collpse the "right half-circle" of $\mathbb{S}^1$ to the basepoint of $\mathbb{S}^1$. Then it could not be the identity as claimed by the other arrow.
Now, I know for sure that I am wrong, but where?
EDIT.
Obviously the answer is: $\mathbb{S}^1$ is not a cogroup object in $\mathbf{Top.}$ but in $\mathbf{HTop.}$.