It is a form of a verb, but it essentially becomes a noun. Which brings me to my next point- [VERBing] is a participle in this case, not a gerund, since it's an adjective modifying "people."
It doesn't become an adjective, it very much remains a verb. If it is, for example, "people dying" then it's not saying "they are dying people", it is saying that the people are currently dying, i.e. an action, using a verb.