There really isn't a right and wrong answer to this, but I will say that the content has to be long enough to answer the question that the page is answering.
In some circumstances, this might mean a short page with just 200 words - other times it might be more. 5000+ sounds a bit insane and like they are trying to over optimise, in which case would make me wonder about the phrase itself - is it low search volume?
There are so many variables that come into play with ranking pages that it would be impossible to say with any degree of certainty what is going on without actually seeing it.
From a usability view, this also sounds very excessive.
Make your pages clear and straight to the point without any waffle - and with 5000+ words, I would be surprised if all of that was really needed.
-Andy