The subjunctive is used with cuando when it is used with the future tense, or describes something that is yet to happen.
For example: 'cuando tenga un gato' (when I have a cat)
Here, the subjunctive is used as the expression implies doubt, as there is no certainty as to whether the speaker will have a cat in the future.