The OP is trying to understand the following question. 
The OP understand that if you can always write out the term $$P(X=k) \implies (1-\frac{1}{N})(1-\frac{1}{N-1})\cdots(1-\frac{1}{N-k+1}),$$ then you can simplify to $\frac{1}{N}$.
The OP wants to learn how to solve those kinds of question using the type of approach proposed by the solution. And how does it different from OP's approach.
You need a final term that give the probability of unlocking with the $k$th key. So $P(X=k) = (1-\frac{1}{N})(1-\frac{1}{N-1})\cdots(1-\frac{1}{N-k+1})\frac{1}{N-k}$ $=\frac{N-1}{N}\frac{N-2}{N-1}\cdots\frac{N-k}{N-k+1}\frac{1}{N-k} = \frac{1}{N} $ by cancellation.
The approach suggested by the solution in the question is combinatorial rather than arithmetic. If correct, both approaches should give the same answer, but in general there is often little direct connection between them, and finding the combinatorial approach requires a mixture of experience and insight.