If the accusation is not necessarily false, you could use label, or for a more strongly negative connotation, brand or denounce.
She gave a convincing testimony, but was denounced as/branded a liar by the prosecutor.
Otherwise, there are a host of words meaning "to falsely accuse" which may be appropriate here.
Slander, defame, calumniate, asperse, malign, smear in addition to traduce mentioned elsewhere.
She gave a convincing testimony, but was maligned/calumniated as a liar by the prosecutor.
Of these, traduce, asperse and calumniate are less likely to be understood.
Here's an interesting comparison of a number of these words from Merriam Webster:
malign, traduce, asperse, vilify, calumniate, defame, slander mean to injure by speaking ill of. Malign suggests specific and often subtle misrepresentation but may not always imply deliberate lying: the most maligned monarch in British history. Traduce stresses the resulting ignominy and distress to the victim: so traduced the governor that he was driven from office. Asperse implies continued attack on a reputation often by indirect or insinuated detraction: both candidates aspersed the other's motives. Vilify implies attempting to destroy a reputation by open and direct abuse: no criminal was more vilified in the press. Calumniate imputes malice to the speaker and falsity to the assertions: falsely calumniated as a traitor. Defame stresses the actual loss of or injury to one's good name: sued them for defaming her reputation. Slander stresses the suffering of the victim: town gossips slandered their good name.