The negative binomial distribution with parameter $r$ is the distribution of the number of times, $X$, a Bernoulli experiment $B$ with probability $p$ has to be repeated independently to have it succeed for the $r$-th time.
Define $X_i$ to be the random variable denoting the number of times $B$ has to to be performed to succeed for the $i$-th time after having succeeded $i-1$ times. $X_i$ is a geometric random variable with probability of success $p$. Therefore the variance of $X_i$ is $\dfrac{1-p}{p^2}$. The $X_i$'s are all independent and hence we have,
$$ Var[X]=Var[\sum_{i=1}^{r} X_i]=\sum _{i=1}^{r}Var[X_i]=r.\dfrac{(1-p)}{p^2}$$$$ \operatorname{Var}[X]=\operatorname{Var} \left[ \sum_{i=1}^r X_i\right]=\sum _{i=1}^r \operatorname{Var}[X_i] = r\cdot\frac{1-p}{p^2}$$