If X has the probability mass function $$\mathbb P(X=n)=\frac{6}{\pi^2n^2}$$ and we are asked to find the expected value, then
$$\mathbb E\left[X\right]=\sum_{n=1}^\infty n \frac{6}{\pi^2n^2} =\frac{6}{\pi^2}\sum_{n=1}^\infty\frac{n}{n^2}$$
Which surely is the harmonic series, which diverges. Therefore, the expected value does not exist. Am I correct?
Yes, you are correct that the expected value doesn't exist.
In this case, we could say that the expected value diverges to $\infty$; there are also two-sided versions of the example for which both the positive and negative parts are divergent.