You have $\text{RSS} = \sum e_i^2 = \sum (Y_i -\beta_0-\beta_1X_i)^2$.
Using the linearity of the expected value we have that
$$\sum \frac{e_i}{n} = E[e]= 0\\=E[(Y -\beta_0-\beta_1X)] = E[Y] -\beta_0-\beta_1E[X]$$
So $\beta_0 = E[Y] -\beta_1E[X]$
$\beta_1$ can be obtained from this:
$$\frac{\partial \text{RSS}}{\partial \beta_1} = -2\sum ( (Y_i -\beta_0-\beta_1X_i) X_i)$$
Setting this to zero
$$\sum ( (Y_i -\beta_0-\beta_1X_i) X_i)=0\\
=\sum ( Y_iX_i -\beta_0X_i-\beta_1X_i^2)\\
=\sum Y_iX_i - \beta_0\sum X_i-\beta_1\sum X_i^2$$
Substituting $\beta_0$ and dividing by $n$:
$$0= \sum \frac{Y_iX_i}{n} - (E[Y] -\beta_1 E[X])\sum \frac{X_i}{n}-\beta_1\sum \frac{X_i^2}{n}\\
=E[YX] - (E[Y] -\beta_1 E[X])E[X]-\beta_1E[X^2]\\
=E[YX] - E[Y]E[X] +\beta_1 (E[X]^2-E[X^2])
$$
Recognizing that $\text{Cov}(Y,X) = E[XY]-E[X]E[Y]$ and $\text{Var}(X) = E[X^2]-E[X]^2$
$$\beta_1 = \frac{\text{Cov}(Y,X)}{\text{Var}(X)}$$
Plugging back into the definition of the $\text{RSS}$
$$\text{RSS} = \sum (Y_i -E[Y] +\beta_1E[X]-\beta_1X_i)^2\\
=\sum (Y_i -E[Y] -\beta_1(X_i - E[X]))^2\\
=\sum ((Y_i -E[Y])^2 + \beta_1^2(X_i - E[X])^2 - 2\beta_1(X_i - E[X])(Y_i -E[Y]) )$$
Breaking this down:
\begin{cases}
\sum (Y_i -E[Y])^2 = n\text{Var}(Y)
\\\sum \beta_1^2(X_i - E[X])^2 = n\beta_1^2 \text{Var}(X) = n \left(\frac{\text{Cov}(Y,X)}{\text{Var}(X)}\right)^2 \text{Var}(X) = n \frac{\text{Cov}^2(Y,X)}{\text{Var}(X)}
\\2\sum \beta_1(X_i - E[X])(Y_i -E[Y]) = 2n\frac{\text{Cov}(Y,X)}{\text{Var}(X)}\text{Cov}(Y,X) = 2n\frac{\text{Cov}^2(Y,X)}{\text{Var}(X)}
\end{cases}
So
$$\text{RSS}
=n\text{Var}(Y) + n \frac{\text{Cov}^2(Y,X)}{\text{Var}(X)} - 2n\frac{\text{Cov}^2(Y,X)}{\text{Var}(X)}\\
=n\text{Var}(Y) - n\frac{\text{Cov}^2(Y,X)}{\text{Var}(X)}$$
Can you do the rest?