Duty is a legal concept, silly Billy.
You can commit a crime by violating a duty. A common one of which you've probably heard is "duty of care" I.e., a doctor can be charged with a crime by not fulfilling their duty of care to a patient.
https://www.forbes.com/advisor/legal/personal-injury/breach-of-duty/
I almost want to look up confidently incorrect. Just maybe learn from this and try googling when you are unfamiliar with a term, you look less silly!