When the contravariant Hom functor of two finite type integral $k$-schemes are isomorphic on points

Let $$k$$ be an Algebraically closed field. Let $$\mathcal C_k$$ be the category of integral $$k$$-schemes of finite type over $$k$$ (the morphisms between two objects being the morphism of schemes that also commutes with the structure morphism to $$k$$) . Let $$\mathcal D_k$$ be the full subcategory (so the morphisms remain the same) of $$\mathcal C_k$$ whose objects have Krull dimension $$0$$. So $$Z \in \mathcal D_k$$ if and only if $$Z \cong Spec (k)$$.

Now let $$X, Y\in \mathcal C_k$$ be such that the functors $$Hom_k (-,X)$$ and $$Hom_k (-,Y)$$ are isomorphic when considered from $$\mathcal D_k \to Set$$ . Then is it true that $$X \cong Y$$ ?

Now I know that $$Hom_k (-,X), Hom_k (-,Y) : \mathcal D_k \to Set$$ are isomorphic means that $$Hom _k (Spec (k), X)$$ and $$Hom_k (Spec(k), Y)$$ are bijective as sets.

Now if I knew that $$Hom _k (Spec (k), X) \cong Hom_k (Spec(k), Y)$$ as locally ringed spaces (where I identify $$Hom _k (Spec (k), X)$$ with the set of closed points $$X(k)$$ of $$X$$ and the structure sheaf I give is the restriction of that of $$X$$) , then I would be able to say $$X \cong Y$$ . Unfortunately, I'm not sure whether I can say that ... Please help

Also note that Yoneda Lemma doesn't apply since $$X,Y$$ are not necessarily in $$\mathcal D_k$$

• Let $X,Y$ be, say two curves and let $f:X(k)\to Y(k)$ be any bijection. This induces a map as you desire, since any map from $\mathrm{spec}\ k\to X(k)$ (or $Y(k)$ ) is a morphism. Am I missing something? Aug 29, 2019 at 1:23
• What happens if $X = Spec(k[t]), Y = Spec(k[t,t^{-1}])$ can you distinguish $Hom_{k-alg}(k[t],k[u]/(f)),Hom_{k-alg}(k[t,t^{-1}],k[u]/(f))$ (is it what your question is about ?). @Mohan also the OP asked a similar question for distinguishing ($\dim \ge 1$) varieties from the curves it contains. Aug 29, 2019 at 2:58
• @reuns If we work in the category of quasi-projective varieties over an algebraically closed field and do the same with the subcategory of one dimensional schemes, I believe the answer is yes. Aug 29, 2019 at 3:15
• @Mohan: a bijection $X(k) \to Y(k)$ induces what map ? I'm not really getting your point ... Aug 29, 2019 at 3:42
• @reuns: yes in case $X,Y$ are affine-varieties say $X=Spec A$ and $Y=Spec B$ where $A,B$ are finitely generated $k$-algebras, I'm asking whether $Hom_k(A,-); Hom_k(B,-): \mathcal D \to Set$ being isomorphic as functors means $A$ and $B$ are isomorphic as $k$-algebras ? Basically if $Hom_k (A,k)$ and $Hom_k (B,k)$ are isomorphic as $k$-algebras then so are $A$ and $B$ but I'm not sure whether $Hom_k (A,k)$ and $Hom_k (B,k)$ are isomorphic as $k$-algebras follows from the isomorphism as functors ... Aug 29, 2019 at 4:45

Your $$\mathcal D_k$$ is equivalent to the category with one object and one morphism, since the only endomorphism of $$\mathrm{Spec} k$$ over itself is the identity and all objects of $$\mathcal D_k$$ are isomorphic. Thus an isomorphism of functors on $$\mathcal D_k$$ is nothing more than a bijection of sets; any two schemes with the same cardinality of their sets of $$k$$-points are isomorphic in this sense, which is certainly much weaker than an isomorphism of schemes.