So let $X,Y$ be real random variables on common probability space $(\Omega, \mathcal{F}, P)$, the measures on Borel $(\mathbb{R},\mathcal{B}_{\mathbb{R}})$ induced by $X$ and $Y$ are equal, that is for all $A \in \mathcal{B}_{\mathbb{R}}$.

$$ P_{X}(A) = P_{Y}(A)$$ where $$P_{X}(A) := P(X^{-1}(A))$$ and

$$P_{Y}(A) := P(Y^{-1}(A))$$

Do $X,Y$ generate the same $\sigma-$algebra? I feel that it might not be necessarily the case but was not able to construct a counter example.

Any help would be appreciated