Definitions: $$R^{-1} \equiv \{z:z=(x,y) \ \land \ \exists x,y((y,x) \in R) \}$$ $$S \circ R \equiv \{(x,z) : \exists y((x,y)\in R\ \land \ (y,z) \in S )\} $$ $\DeclareMathOperator{\Id}{Id}$ $$\Id_{\mkern1mu\operatorname{dom}(R)} \equiv \{(x,z):x,z\in \operatorname{dom}(R) \ \land \ x=z \}. $$
I understand why $\Id_{\mkern1mu\operatorname{dom}(R)} \subseteq R^{-1} \circ R $ holds.
But it isn't clear that $R^{-1} \circ R \subseteq \Id_{\mkern1mu\operatorname{dom}R}$ has to hold since $\exists y((x,y) \in R \ \land \ (z,y) \in R) \Rightarrow (x=z)$ makes no sense to me.
Thanks in advance.
Your definition of $R^{-1}$ is wrong: it should be $$R^{-1}=\{(y,x)\,:\, (x,y)\in R\}=\{z\,:\, \exists x\in X,\exists y\in Y, ((x,y)\in R\land z=(y,x))\}$$
Provided of course that $R$ is a relation from $X$ to $Y$.
However, $R^{-1}\circ R\supsetneq \operatorname{Id}_{\operatorname{dom }R}$ is entirely possible. See, for instance, $R=X\times Y$, for which $R^{-1}=Y\times X$ and $R^{-1}\circ R=R$, which is not $\operatorname{Id}_{\operatorname{dom }R}$ unless $Y=\emptyset\lor X=\emptyset\lor (\lvert X\rvert=\lvert Y\rvert=1)$.