Workflow - Remove entitlements when a identity turns inactive

Hello Soundarya,
You may follow the below link which will give you the high level information to your Workflow approach which considers the Workflow limitation, sticky entitlements and AD group default behaviors.

Let me know whether it helps you.