You gave the answer yourself: RooVoigtian takes a RooAbsReal as resolution argument, not a RooRealVar, so one can simply enter
a formula here that depends on the mass, e.g.
// Observable
RooRealVar m(“m”,“m”,-10,10) ;
// Resolution as function of mass
RooRealVar a(“a”,“a”,0.1,-1,1) ;
RooFormulaVar sigma(“sigma”,“m*a+1”,RooArgSet(m,a)) ;