In pages on Mac or Word on Windows I can use speech to text. How do I do that in LibreOffice writer?
As far as I know it is not possible. LibreOffice is designed as an Desktop Office Suite not for your phone.
Have a look at question can you go from speech to text in Libre Office? . Cheers Al
As indicated by others, the speech-to-text is not built into the app, but into the underlying system (OS), either natively or by way of a resident/plugin driver/software.
In Windows you must have the function enabled in accessibility settings. IIRC, you activate dictation mode by keyboard shortcut Windows+H.
In MacOS I have zero experience, but this page (linked) seems to explain a procedure to enable it.