We present a claim that trivializes the problem.
Claim. Let $x$ and $y$ be positive integers such that $x\equiv y\pmod{3}$, and $f$ a polynomial with integer coefficients. Then $f(x)\equiv f(y)\pmod{3}$.
Proof. Let $f(x)=a_nx^n+a_{n-1}x^{n-1}+\dots+a_0$. Now $x\equiv y\pmod{3}$ implies $x^k\equiv y^k\pmod{3}$ for positive integers $k$, and in particular for all $0\leq k\leq n$. Equivalently, $a_kx^k\equiv a_ky^k\pmod{3}$, and summing over $0\leq k\leq n$ yields the desired result. $\Box$
Now, $k$, $k+1$, and $k+2$ taken modulo $3$ are $0$, $1$, and $2$ in some order. In particular, all integers $m$ are equivalent to one of $k$, $k+1$, and $k+2$ mod $3$, so $f(m)$ is equivalent to one of $f(k)$, $f(k+1)$, $f(k+2)$ mod $3$, all of which are $0$. Hence, $f(m)\equiv0\pmod{3}$ for all integers $m$, as requested. $\blacksquare$