'tam' is 'there' (over there).
Some of those thing depend on cases, so this is a very broad topic. Please look for topics about cases here: https://www.duolingo.com/comment/16296174
As other things are concerned: firstly, Polish and English have a different perception of 'closeness'. While in English "that" is perfectly natural usually, Polish "tamten" and its forms aren't used that often. "tamten" is in fact more like "that one over there". In short words, English goes like this: "this/that/that" while Polish has "ten/ten/tamten". The first "that" overlaps with second "ten", which is why we accept such translations although they aren't literal translations ("ten" = "this", "tamten" = "that").
Another thing: gender. The determiner depends on the gender of the noun it describes. Staying in Nominative (the basic, dictionary form), you have: ten/ta/to ('this' for masculine, feminine, neuter) and ci/te ('these' for masculine personal plural and not masculine-personal plural). For "that"/"those" you just start the word with "tam".