It does not answer why PDFs can have virus.
> PDFs, like other file formats, can have hidden JavaScript code that might exploit vulnerabilities in a PDF.
and
> Opening a malicious PDF can launch malware that will start up whatever process the hacker has in mind.