User Role Permission Based On Document Number

In ERPnext, how do I create user permissions based on document number…?
For example, in Material Request: User ‘A’ can only view and edit documents that contain the word ‘DTA’ (ex: MR-DTA-00001)
Or is it also possible to limit it based on the Cost Center?
So for example user ‘A’ can only access documents with a certain cost center.

Yes, you can set user permission based on cost center.
https://docs.erpnext.com/docs/user/manual/en/user-permissions