You want to enable ContentExtraction.EnableMetaData setting for a cloud-managed REST Detector. For on-prem detector, please check this KB Data Loss Prevention is not detecting file metadata.
This is part of the advanced settings in the Edit Detector Settings option. By default, this setting is hidden behind a feature flag. Please create a support ticket if you want to enable this for your tenant.