OK, here we go. You're using Catalina, so I believe the default shell for your system is 'zsh' instead of 'bash', which was the default under High Sierra.
Create a plain text file that contains the line
alias batch_convert="/Applications/LibreOffice.app/Contents/MacOS/soffice --headless --convert-to pdf"
You can do this in TextEdit, but you will need to select the "Make Plain Text" item in the Format menu before it will allow you to save the file as plain text. Save the file. Run Terminal. At the command prompt, type the following 'ls' (directory) command. This is just to check that you don't already have an initialization script (if you did, then you'd probably want to add that line to it, rather than overwriting all of the old commands).
% ls .zshrc
ls: .zshrc: No such file or directory
Now type cp, and a space. Drag and drop the file you saved with TextEdit into the Terminal window. Type another space, then .zshrc (with a leading '.'). You'll see a command like this (where dragging and dropping the Finder file will have filled in its entire Unix pathname for you).
% cp /Users/-----/Desktop/ZSHRC.TXT .zshrc
Hit RETURN. Now when zsh starts, your .zsh will set up a "batch_convert" convenience command. Exit Terminal and launch it again (to restart zsh and make it set up the alias.)
Now, if you have some Word files, e.g.,
% ls *.pdf
Word Test Document One.pdf Word Test Document Two.pdf
You can do a
% batch_convert Word\ Test\ Document\ One.docx Word\ Test\ Document\ Two.docx
LibreOffice will print
convert /Users/-----/Word Test Document One.docx -> /Users/-----/Word Test Document One.pdf using writer_pdf_Export
convert /Users/-----/Word Test Document Two.docx -> /Users/-----/Word Test Document Two.pdf using writer_pdf_Export
and a directory listing will then show
% ls *.pdf
Word Test Document One.pdf Word Test Document Two.pdf
I checked the .PDF files with Preview, and their contents looked fine to me.
I tried doing a
% batch_convert *.docx
and that worked too – the spaces in the filenames didn't throw it off, the way they would if I typed them without escape prefixes on the command line. (When I did that, LibreOffice appeared to do nothing; it did not generate any .PDF files, or any success messages, but it also didn't generate any error messages.)
If you wanted to use the --outdir directory option shown in the third link (batch conversion on OS X), you would just type
% batch_convert --outdir directory input_files