Raspberry pi has a feature where when it's connected to a LAN, you can find its IP using raspberrypi.local
(source). It mentions multicast DNS.
I'd like to do this for my own linux devices on LAN, giving them names of my choice (e.g. "xyz.local") how can it be achieved?