The girl could volunteer in an after-school study program to teach kids.
—— volunteer in:自愿参加(某项活动,某个项目)。 to teach kids 是program 的定语。与不定式存在“同位关系”。
I'm making some plans to work in an old people's house this summer.
—— work in an old people's house this summer,也是 plans 的定语。它们的关系,由于动词 plan 可以接不定式作宾语,所以,名词 plan 跟不定式,也存在这种动宾关系。
总之,两个不定式都是作定语,只是修饰关系不同而已。