I think your problem is PVC and ABS plastic pipe and fittings have very close tolerances and will not dry fit. The stuff we commonly call PVC "glue" is not glue, but a solvent. When you apply the solvent to the pipe end and fitting interior, the surfaces each melt and allow the pieces to slip together. The liquid surfaces blend together and hen the solvent drys, solvent solvent weld is made. Measure the depth of the closet bend and the length of the flange to make sure there is enough space for the pieces, then apply primer and solvent to both surfaces. press together with a slight twisting motion, make sure the flange is oriented correctly, then hold the flange down for a few seconds to prevent the parts to separate. This is the basic principal of "gluing" all PVC and ABS pipes and fittings. PVC requires primer, ABS does not.