Philosophy is able to be the handmaid of theology because it is independent of theology, and based on its own principles. A philosophy that was neither independent nor truly and totally rational could not be an aid to theology, because it wouldn’t exist at all, much less help anything. Philosophy’s independence constitutes an essential part of its value as a handmaid.
It does not follow from this that philosophy is any less rational because it borrows various theses from revealed theology and then establishes them on rational grounds. This is in fact a rather unremarkable thing: just another instance of starting with something unknown and then finding a middle term to prove it.