To get this done for all your documents, make sure to enable the Document ID feature in the site collection(s) where your SharePoint libraries are. Read here how: https://support.microsoft.com/en-us/office/activate-and-configure-document-ids-in-a-site-collection-66345c77-f079-4104-ac7a-e25826849306
When you enable Document IDs for a site collection, a column is added to the Document and Document Sets Content Types at the site collection level. The ID assigned to an item appears in the Document ID column. Find the Document ID in the details pane of the document library.
It make take some time but eventually all your documents will have been populated with an unique Document ID.
So: No need to run a batch job or powershell for this