How to replace a device?

I did try search, but only found discussions from 2+ years ago so I’m asking fresh.

I have a Leviton switch that is used in a few lighting automations and a Dashboard. The switch (DW15s Gen1) has failed, and I will replace it with a D215S Gen2. Since this is the first time I’m replacing an active component of HA, I’m asking to understand the proper process?

Thanks in advance!
//Brew