Even if this is old, also in 2021, to manipulate open documents works as easy as before, if it was generated with microsoft office, office 365, google docs, libreoffice or openoffice:
make a copy of you document
rename extension of the copied document to .zip (because every open document is a zip file!)
create a folder with the document name, without extension
copy the renamed document (zip file) from step 2) into this folder
extract the (document) zip file within this folder
delete the zip file!
... change xml data and binary objects as you like
mark all files an folders within this folder and add them to a new zip file (only use standard zip compression!)
now you should have a new zip file within the folder you created before in setp 3)
rename the extension of this new zip file back to o.odt or .odp or whatever the original open document type was, you renamed in step 2)
try to open this new, renamed open document in any office software able to handle open document files
Please remember:
a) every open document is a (compressed) zip file
b) the zip file contains xml files which represent the structure and text-content of this document and it also contains supfolders with binary datas (objects), like media data (images, audio or video data, and ole objects), some of them may appear as base64 coded within an xml file.
c) you can extract the content of each open document into a new folder
d) never compress the folder where you put all your data, to create a new zip file/open document file. ONLY compress the content of this folder, to create a valid open document and rename the so created zip file to the open document extension his original source file used!
Sources: https://en.wikipedia.org/wiki/OpenDocument_technical_specification
Tools you can use to manipulate open document files:
a) https://7-zip.de/download.html (to extract and compress)
b) https://notepad-plus-plus.org/downloads/ (to edit the XML content)
c) https://www.bulkrenameutility.co.uk/ (to bulk rename files and folders if you do not know the command under windows, linux ...see: https://unix.stackexchange.com/questions/181141/rename-multiple-files-with-mv-to-change-the-extension)