Just to be clear, the statement that you're asking about is really this: given a function $f:X\to Y$, the following two statements are equivalent:
- $f$ is one-to-one
- For any two sets $S, T\subseteq X$, we have $f(S\cap T) = f(S)\cap f(T)$
Or, to be more specific, you are looking at their inverses:
- $f$ is not one-to-one
- There exists $S, T\subseteq X$ such that $f(S\cap T)\neq f(S)\cap f(T)$
Below is a proof of the equivalence of the latter pair:
Note that no matter the function, $f(S\cap T) \subseteq f(S)\cap f(T)$. If there are $S$ and $T$ such that $f(S ∩ T) \neq f(S) ∩ f(T)$, then we know that there is some $y\in f(S)\cap f(T)$ which is not contained in $f(S\cap T)$. In that case, $y\in f(S)\cap f(T)$ means that we have both $y\in f(S)$ and $y\in f(T)$, which in turn means that there is an $x_1\in S$ such that $f(x_1) = y$, and there is an $x_2\in T$ such that $f(x_2) = y$. However, netiher $x_1$ nor $x_2$ are contained in $S\cap T$, because $y\notin f(S, T)$. That means that $x_1$ and $x_2$ must be different, which makes them a witness against $f$ being one-to-one.
For the other direction, if $f$ is not one-to-one, then there are some $x_1 \neq x_2$ with $f(x_1) = f(x_2)$. Let $S = \{x_1\}$ and $T = \{x_2\}$, and you're done.