Let $A=k[x_1,\ldots,x_m]$ and $B=k[y_1,\ldots,y_n]$ over some algebraically closed field $k$. Let $\psi : \mathbb{A}^n\rightarrow \mathbb{A}^m$ be the morphism corresponding to a $k$-algebra homomorphism $\phi: A\rightarrow B$. Let $a=(a_1,\ldots,a_n)\in \mathbb{A}^n$ and $\psi(a)=(b_1,\ldots,b_m)\in\mathbb{A}^m$. I want to show that $\phi^{-1}((y_1-a_1,\ldots,y_n-a_n))=(x_1-b_1,\ldots,x_m-b_m)$.
I know that since $\phi$ is a $k$-algebra homomorphism and $A$ and $B$ are finitely generated $k$-algebra, then the preimage of a maximal ideal is again a maximal ideal. I also know that by Hilberts Nullstellensatz, then a point $(a_1,\ldots,a_n)$ in a affine variety corresponds to the maximal ideal $(a_1-p_1,\ldots,x_n-a_n)$. And by how $\psi$ is defined on the point $a$, then this seems to be natural that $\phi^{-1}((y_1-a_1,\ldots,y_n-a_n))=(x_1-b_1,\ldots,x_m-b_m)$. However I was wondering if there were a more rigorously way of doing it or seeing it. My argument seems a little loose.