Previously, I do believe $S^2$ is an unbiased estimator of $\sigma^2$
$$S^2 = \frac{1}{n-1}\sum_{i=1}^n{\left(X_i-\bar{X}\right)^2}$$
is a correct conclusion.
However, I found the following statement:
Considering the sample variance:
$$s^2 = \frac{1}{n-1}\sum_{i=1}^{n}\left(y_i -\bar{y}\right)^2$$
it can be shown (see Appendix A, Derivations) that
$$E(s^2) = \frac{N}{N-1}\sigma^{2}$$
This is an example based on simple random sample without replacement. It says $S^2$ is a biased estimator of $\sigma^2$.
So I am wondering "$S^2$ is an unbiased estimator of $\sigma^2$" can only be applied to some specific cases? How to understand this result based on simple random sample?