Distance from a point in a set to a subset of that set is Lipschitz
Let $x,y \in X$
then $\forall z \in Y$ we have $d(x,Y) \leq d(x,z) \leq d(x,y)+d(y,z)$
Thus $$d(x,Y) \leq d(x,y)+d(y,Y) \Longrightarrow d(x,Y)-d(y,Y) \leq d(x,y)$$
Now similarly
$\forall z \in Y$ we have $$d(y,Y) \leq d(y,z) \leq d(x,y)+d(x,z)\Longrightarrow d(x,Y) \leq d(x,y) +d(x,Y)$$
So $d(y,Y)-d(x,Y) \leq d(x,y)$
Combining the above we have that $|d(y,Y)-d(x,Y) |\leq d(x,y)$
We have $d(x, x')+d(x', y) \ge d(x, y)\ge d(x, Y)$ for any $y\in Y$.
So, taking infimum for $y\in Y$, we get
$$d(x, x') +d(x', Y) \ge d(x, Y)$$
So, $d(x, Y)-d(x', Y) \le d(x, x')$.
By symmetry, we also get $d(x',Y) - d(x,Y)\le d(x, x')$.