I got to know that dono hito specifically asks about a person while donata is for who in general, so does taht imply to all living beings? Are both used in formal conversations?(If yes, which is preferable?)
どのひと (dono hito) is "which person", どなた (donata) is "who".
どの (dono) by itself is "which". You use どの when you want to select the correct one among three or more options. どのひと is used when you are seeing three or more people and want to know which is the right person.
どの本ですか？ (Dono hon desu ka?)
Which book (do you want)?
どなた is a polite version of だれ (dare), which just means "who". You use どなた when you ask who someone is, who comes, who will do a job, etc.
どなたですか？ (Donata desu ka?)
Who's there? / Who is she? / etc.