I am trying to add new tags on customer based on shipping address at the time of purchase through Shopify script editor. Went through this doc but didn't get anything related to it.
Use Shopify Flow. If you have Plus, which you seem to, Flow can alter customer records based on Orders.