Let $k$ be an algebraically closed field, $A$ a finitely generated $k$-algebra. Let $x,y$ be two distinct closed points of $\mathrm{Spec}(A)$. Is there an affine $k$-scheme of finite type obtained from $\mathrm{Spec}(A)$ by "gluing $x$ and $y$"? More precisely: let $\mathfrak{m}_x$ and $\mathfrak{m}_y$ be the maximal ideals of $A$ corresponding to $x$ and $y$, and $I=\mathfrak{m}_x\cap \mathfrak{m}_y$. Define $B$ to be the $k$-subalgebra of $A$ generated by $k$ and the elements of $I$. Is $B$ a finitely generated algebra over $k$?
In Serre's book "Algebraic groups and class fields" he carries out the construction for smooth curves (i.e. $A$ normal and of dimension 1) but I don't see how to generalize this to higher dimension.