@dmaritim This error typically occurs when there are coordinate values not expected by dhis2. The db column does not support z dimensions, and it looks like some of your org unit coordinate values are having those unsupported values.
You will get the same error when you try this
select ST_SetSRID(ST_GeomFromGeoJSON('{"type":"MultiPolygon", "coordinates":' || coordinates || '}'), 4326) from organisationunit
where featuretype in ('POLYGON', 'MULTI_POLYGON');
If its possible to share your organisation unit data by email, we can take a look at what the incorrect values are.
Or if you are okay with deleting all coordinate data for “POLYGON” and “MULTI_POLYGON”, that should also sort this issue out (but you will lose coordinate data for those org units)