The twin aspects:
Defamation has both the civil and criminal aspects. And you can seek remedy under either or both.
If it is a civil case, you can claim compensation.
If it is criminal, you can get the accused convicted .
The basic ingredients of a defamation complaint:
Public post: it must be posted on a public platform. A private message may not constitute defamation.
Defamatory & False allegation: It must be a false allegation and defamatory to the extent it has harmed & lowered the prestige in eyes of others.
If any allegation is “imputation of truth” which is required for the “public good” and thus has to be published that is not defamation.