You mentioned "credit"---assuming you mean the child tax credit, you cannot get the child tax credit (or stimulus money) for a child who was over the age of 16 at the end of 2020. You lose the child tax credit in the tax year that a child turns 17. If the 17 year old child is your dependent you get the $500 credit for other dependents for that child instead of the CTC.
CREDIT FOR OTHER DEPENDENTS
however, if you received the stimulus payment last spring, when your older grandchild would have been listed as 16 years old on the 2019 tax return, you will not be required to return that money. Review Line 30 on Form 1040.