This question was earlier answered in 2015 that Word cannot save a PDF and retain custom document properties.
These custom document properties are added to the Word document by a SharePoint Online Library columns (metadata).
The given answer says that if Adobe Acrobat is installed, choose the Acrobat tab on the Ribbon, then Create PDF. Your custom properties will be saved in the PDF.
Please tell me what the minimal requirements are for the Adobe Acrobat product, I'm using Word 365 latest version.