I've read the definition of composition algebra in wikipedia, but I couldn't understand whether it relates to the usual function composition $(\circ)$.
Are these two things related at all?
Considering functions of type $\mathbb R \to \mathbb R$ will suffice.
From the comments: no, they are not related. The concept of function composition $\circ$ is embedded into composition ring, not the composition algebra. So yes, it may be quite misleading.