The theme is, as others have said, the belated recognition by a son of the boundless love a mother has for her child.
Looking up the word "lanyard" triggers a childhood memory as powerful in the speaker as the memories famously triggered by the madeline, a kind of French cookie, in Proust, as the speaker explains below:
No cookie nibbled by a French novelist
could send one into the past more suddenly
When he sees the word lanyard, the speaker is transported back to summer camp, where he painstakingly, with the help of a counselor, made a lanyard for his mother. He ruefully compares the tiny gift of the lanyard to all his mother did for him:
Here are thousands of meals, she said,
and here is clothing and a good education.
She also cared for him when he was sick, and taught him to "walk and swim."
As we can see, a lanyard seems a wholly inadequate repayment.
Yet in the last lines, we also see that the young child is so secure in his mother's love and in his love for her, that he is "sure"
that this useless, worthless thing I wove
out of boredom would be enough to make us even.
This is a wry look back at the innocence of childhood and at the child's naive reduction of love to a transaction, for, of course, such love can never be paid back, only paid forward. The theme is not regret for what can't be paid back, but recognition of the love that was bestowed.