@testtttt1 I see two issues here. The filename dam:batch.metadata.json which you are trying to persist, should not have colon ( : ) in the file name. Also, while persisting this filem, you might not be adding correct nodetype, it should be nt:file as node type.
Can you please add the code snippet for this?