When you attach a PDF document to a tax return it is compressed and encrypted, then becomes part of the return data. When you electronically file the return it goes with the return to the IRS or the state (wherever it's attached).
But unlike the tax return forms and schedules, the PDF attachment isn't included in the print sets nor with the output when you preview the return. This is normal behavior.
If you need to view a PDF attachment, the menu where it is attached typically lists it along with a pencil icon that can be clicked to open it in a separate tab in the web browser.