A usual way that we show this is by writing the random walk as

$$y_t = \sum_{i=1}^tu_t$$
and so

$$\operatorname{Var}(y_t) = \operatorname{Var}\left(\sum_{i=1}^tu_i\right) = t\sigma^2$$

and

$$\operatorname{Cov}(y_t, y_{t+k})= E\left(\sum_{i=1}^tu_i\right)\left(\sum_{i=1}^{t+k}u_i\right)-E\left(\sum_{i=1}^tu_i\right)E\left(\sum_{i=1}^{t+k}u_i\right)$$

$$=E\left(\sum_{i=1}^tu_i\right)\left(\sum_{i=1}^{t}u_i+ \sum_{i=t+1}^{t+k}u_i\right) -0$$

$$=E\left(\sum_{i=1}^tu_i\right)\left(\sum_{i=1}^{t}u_i\right)+E\left(\sum_{i=1}^tu_i\right)\left(\sum_{i=t+1}^{t+k}u_i\right) $$

$$=t\sigma^2$$
again, and depending on $t$. In fact one could start by calculating the covariance, find out that it does not depend on $k$, then set $k=0$ and obtain also the variance.