The detective, whose name was not released, was detained by investigators Monday and questioned, said Sgt. Trent Crump.
"He then submitted his resignation to his superior," Crump said. "He was released as we continue the investigation. We know who he is, where he lives and we don't think he's going anywhere."
Crump said that the department's Professional Standards Bureau does regular audits of drugs that are kept as evidence and that a recent audit of drugs destined for destruction revealed "that some of them had been swapped out.
Most of the pills swapped were Oxycodone, he said, though other drugs were missing.
Crump said that since the detective had access to the department's case management system, it was easy for him to see what drugs might be available. And since he had the authority to check the drugs out of the evidence room, Crump said, it was easy for him to take them, swap an over the counter drug into the bottles and then return the containers.
Crump said the department is working with the Maricopa County Attorney's Office to build a case against the detective.
He said the suspect could face charges of felony theft and drug possession.