Hi Anusha Sinha,
Hope you find it helpful!
Alternatively, you could create an Action button with a Microflow linked to it.
In my case, the datagrid holds a list of Departments. And below is the simple microflow
Make sure you take a look at who has access to the microflow and maybe add the confirmation pop up (via microflow settings)
Hope this helps.