"When do you finish work today?"
Translation:너는 오늘 언제 퇴근하니?
니 is the ending of interrogative written form. In other words, it is used to form questions in 'written' form (also known as 'diary' form or 'formal impolite')
It is completly interchangable with 느냐 suffix, both serve the same purpose
집에 가니? / 집에 가느냐? - do you go home?
I would strongly suggest to throughly redo the unit 'written' of Duolingo