This sounds a bit like the idea behind collider bias, the reverse of confounding bias.
- Confounding bias: x and y are found to be correlated because both are caused by z.
- Collider bias: x and y are found to be correlated because they both cause
z and there is a selection effect based on z.
Image from the question:Can spurious correlations exist in the (theoretical) population?
So $X$ and $Y$ may not be correlated, but when you condition on $s$ then they are correlated.
It is written a bit implicitly in the interview question but the statement implies a conditioning
Given that ... and you know $X+Y=s$
You might assume that this means a particular sampled individual case has $X+Y=s$. Otherwise there is a contradiction. $X$ and $Y$ can not be independent while also $X+Y=s$.