The Polish word Niemcy is peculiar: the word "Slavs" literally means "word people" while "Germans" literally means "mute/unintelligable people". I.e. the word originally meant something like "anyone we don't understand" (similar to the Greek word "barbarian" - someone who says bar-bar, some gibberish). Apparently, at some point the most common type of an unintelligable person you'd meet was someone from a Germanic tribe, so the word began to mean "Germanic". A few centuries ago the word still meant "Germanic" in Russian, people used it to refer to the Dutch and Swedes as well. I can guess Germans have been the most common type of a Germanic person in the last few centuries so the word's meaning was narrowed again and now exclusively means "German".
Tyskland and Deutschland stem from the same root teud- "people, folk", so it's literally "land of the people". Interestingly, the word was borrowed into Slavic and now means "foreigner, stranger" (Russian "chuzhoy", Czech "cizinec"). In Russian a derivation "chush" also means "gibberish" (we've come a full circle).