This double meaning is present with chodzić:
Chodzę z tą dziewczyną" could mean I'm dating this girl" (girl rather than woman).
Iść, idę don't have this connotation.
The difference is between "instrumental" and "comitative". Both of these are expressed using "with" in English, but in Polish they are distinguished. Instrumental (when using something as a tool) uses the bare instrumental case, while comitative (indicates a companion for the action) uses z+instrumental.
"tamten", "tamta" and "tamto" definitely need to be translated as "that", however "ten", "ta" and "to" can be either translated to "this" (the main translation here) or "that" (accepted translation).
We could say that "[this/that/that]" translates to "[ten/ten/tamten]" and its forms. There is an overlap of the middle options.
Is there a rule to follow by to not confuse the possible translations, thus the possible distances indicated through those determiners? If we can change ten and tamten (these two “classes”, as I shall call them here) intelligibly? Maybe one can extract it from context and perhaps the sentence's structure, but above this, is there a grammatical rule to keep in mind? Anything?