You have created a new external number range for purchase orders in configuration.
When you try to add your new number range to any existing purchase orders you receive error "Enter valid document type" (CZ320).
SAP S/4Hana Cloud - All Versions
Reproducing the Issue
1) Create a new external number range in customising 'Define Number Ranges for Purchasing Documents' SSCUI 103412
2) Try to change the external number range of PO type NB in customising 'Define Document Types for Purchase Orders' SSCUI 102909
The standard delivered content cannot be changed. Error "Enter valid document type", in this context means the document type (in which the number range was changed) isn't in the customer namespace.
Create a custom PO type and assign the new custom external number range to it.
VV_T161_VF, SIMG_CFMENUOLMEOMEC, Define Document Types, 103412, 102909, T161-BSART, NUMKE, V_T161 , KBA , MM-PUR-PO , Purchase Orders , Problem