# What's the name of this theorem (multivariate polynomial factorization)?

I have proven the following theorem:

Let $$p(\vec{x}), q(\vec{x})\in\mathbb{F}[\vec{x}]$$ be multivariate polynomials in $$n$$ variables. If $$q$$ is linear and $$q(\vec{x}) = 0$$ implies $$p(\vec{x}) = 0$$ for all $$\vec{x} \in \mathbb{F}^n$$, then $$q$$ is a factor of $$p$$.

I do not know the name of this theorem. I am wondering what theory(ies) or field(s) of mathematics this theorem relates to, and whether this theorem can be generalized.

In particular, the theorem fails if $$q$$ is only required to be irreducible rather than linear. Take $$p = (x^2-1)^2 + (y^2-1)^2$$ and $$q = (x-1)^2 + (y-1)^2$$ with $$\mathbb{F} = \mathbb{R}$$.

I have tried searching for a while, but could not find much (likely because I do not know what keywords to search for).

Any help is greatly appreciated!

After a bit more searching, I discovered that this theorem is a special case of Bézout's theorem. The generalization to irreducible $$q$$ is true as long as $$p$$ and $$q$$ share infinitely many zeroes.