What is Regretting?
Replaying what you wish you'd done. Sometimes useful, often not — depends on what you do with it.
When you might feel regretting
Regretting is a specific form of guilt, which itself is a type of self-blame. You might experience this feeling in situations where self-blame is present, particularly when the circumstances align with the nuances that define regretting.