Purdue Pharma LP pleaded guilty to criminal charges over the handling of the company’s addictive prescription painkiller OxyContin, capping a deal with federal prosecutors to resolve an investigation into the drugmaker’s role in the U.S. opioid crisis.