The correct option is:
B). To translate domain names into IP addresses.
The Domain Name System (DNS) is responsible for converting human-readable domain names (like www.example.com) into machine-readable IP addresses (like 192.0.2.1), allowing users to access websites using easily memorable names rather than numerical addresses.