To express 'ago' put томЎ назђд after the Accusative unit of time.
The word томЎ is optional in this expression. The Accusative unit is the time-noun if no numeral accompanies it (недљлю) or the numeral itself, in which case the time-noun will be governed by the numeral (пїть [Acc.] недљль [Gen. Plur.]).
Recall that 'long ago' is expressed by the word давнћ.
Онђ љздила тудђ недљлю (томЎ) назђд. She went there a week ago.
Онђ љздила тудђ двљ недљли (томЎ) назђд. She went there two weeks ago.
Онђ љздила тудђ пїть недљль (томЎ) назђд. She went there five weeks ago.
Онђ љздила тудђ давнћ. She went there a long time ago.