The're expanding R&D very rapidly, quadrupling their spend on it over the last 6 years. For a mature company with an already well established product development operation that's pretty astounding. It's just that they became so immensely profitable so fast, their profits in absolute numbers still dwarf it.
Additionally, the amount of cash Apple has on hand doesn't strike me as people plunging a major amount of their cash reserves into R&D. Much the opposite, actually.