How to convert your document to PDF
This should be an option in just about every program that you come across on Windows, although certain applications will have more specific PDF-related features. The ability to save as PDF is built right into Microsoft Word for Windows, for example: Choose File, then Save as, and PDF is listed as one of the file types to the left of the Save button.
macOS
Get to the print dialog from any of your programs, and then in the Destination drop-down, pick Save as PDF. So in the Safari web browser, for example, you can turn any webpage into a PDF by choosing File and then Print, and then selecting the PDF option (lower left). Pick Save as PDF to choose a filename and destination.
There's PDF functionality built right into Finder as well. If you select multiple files and then Ctrl+click on the selection, you can pick Quick Actions and Create PDF to do just that (most common file types are supported).
When it comes to Android, your first port of call should probably be the app that you're creating the original file in. In the case of Google Docs for Android, with a document open you can tap the three dots (top right), then choose Share and export, Save as, and PDF document to generate a PDF—you can then view it onscreen, share it with others, and download it to your device.
As you might have predicted by now, the classic print-as-PDF option is available on Android too. Find the Share button in any app, and that should lead you to Print, and from there you can pick Save as PDF as the printer.