As you have correctly stated, the DNA cannot directly react with diphenylamine. First, it has to be _cleaved_ so that the deoxyribose is exposed. In acidic solution and at high temperature, a depurination occurs several orders of magnitude faster than depyrimidination, because N-7 of the purine can be protonated and assist the cleavage.
See this mechanism of the acid-catalyzed depurination:
![Acid-catalyzed depurination](