This is also one of the notable Kafka interview questions that you may come across. Zookeeper is primarily responsible for developing coordination between the different nodes in a cluster. Zookeeper can help in recovery from previously committed to offsetting in the event of failure of a node because it works as periodically commit offset.
In addition, Zookeeper also helps in leader detection, configuration management, synchronization, and detecting any node leaving or joining the cluster. Furthermore, Kafka implements Zookeeper as storage for offsets of consumed messages regarding a specific topic. Zookeeper also helps in partitioning the offsets of messages according to specific Consumer Groups.