Femtoscopy with identified hadrons in pp, pPb, and peripheral PbPb collisions in CMS