"In which country do you live?"
Translation:В какой стране ты живёшь?
"какой" is the prepositional of "какая". Prepositional is used because of "в" to indicate "in".
The prepositional of "какой" would be "каком".
You can check the full table here:
Yes, just like English "in". Otherwise it would be "Which country do you live?", which is generally wrong or at least a very unusual question (what does it mean "to live a country"? ).
Note however that "страна" is feminine. "Какой" is the prepositional of (nominative) "Какая", and not the nominative masculine "Какой", because of "В". The hypothetical strange question without "в" would read
Какая страна ты живёшь?
It would probably read "Какую страну ты живёшь?" in fact due to accusative (you [subject] live the country [direct object]), but it is hard to say given such an unusual question :P
Subject, for the millionth time, is NOT required in simple sentences where the conjugated verb implies the subject of the sentence.
Я написал: В которой стране вы живёте. It says that it si wrong. Does somebody knows why?
Нет. Правильно "в какой" а не в "которой". "в которой" means it is a statement not a question. "В какой стране вы живете?". "Страна, в которой я живу".
I believe that которой would be ok in a multiple choice question, like there were three listed countries, and the listener is expected to reply to the question with "the first", "the second" or "the third". In a general purpose question without a fixed set of answers yes, all I have seen so far suggests that какой is the right choice.