Translation:These are not sandwiches, these are cookies!
If to stands on its own as a predicative sentence subject, it can be used regardless of whether it refers to a single object or multiple objects. So that explains this/these.
As for that/those, the Polish equivalent tamto is used very sparingly, mostly to contrast with to. If there is no need to contrast, you can use to regardless of distance.