Suppose a polynomial $P(x_1,\cdots,x_n)$ is given. Does there exist a function $\phi\in\mathcal{S}(\mathbb{R}^n)$ such that supp$(\phi)\subset\mathbb{S}^{n-1}$ and $\int_{\mathbb{R}^n}P(X)\phi(X)\,dX=0?$
notation:$\,\mathbb{S}^{n-1}$is the unit sphere of $\mathbb{R}^n,\,\mathcal{S}(\mathbb{R}^n)$ is the Schwartz space, and $X=(x_1,\cdots,x_n),\,$
I think you probably want to integrate over the sphere using surface measure (otherwise, if you integrate over $\mathbb R^n$, $\textrm{supp}(\phi)$ is measure zero).
In this case, let $\phi$ be any spherical harmonic. If $\int P\phi = 0$, you are done. Otherwise, let
$$ \psi = \phi - \frac{1}{|P|^2}\left(\int P\phi\right)P $$
where $|P|^2 = \int_{\mathbb S^{n-1}}P^2$. Assume for the moment that $\psi \neq 0$. Then
$$ \int\psi P = \int \phi P - \frac{1}{|P^2}\left(\int P\phi\right)\int P^2 = 0. $$
If $\psi \equiv 0$, then $P = c\phi$ for some constant $c$. In this case, just choose $\tilde \psi$ to be any other spherical harmonic, and you will get the result (the spherical harmonics are orthogonal).