Best thing to do is check the Xfinity web site for the current modem list at https://mydeviceinfo.xfinity.com/ and see if your modem is listed. If your modem is not listed, I would not recommend it as it would not be supported although it may work.
Buying your own equipment is cheaper in the long run. You do have the hassle of getting it set up but setting up a modem is simple if you follow the instructions from Comcast.
You can get any one of the modems listed for your speed or a higher speed tier. I recommend you get a new one and from a place that accepts returns in case you have an issue. When buying a modem, consider more than the cost. Buying the lowest cost one may require you replacing it sooner when it reaches the end of life and no longer supported. One that supports faster speed than your tier will give you room to grow into if Xfinity speeds up your tier like they did last year for my tier or if you decide to up your tier. A modem that has more up load and down load channels will give you more stable speeds and you need IPv6. Xfinity just started a rollout of the DOCSIS 3.1 and the older version 3.0 should be supported for quite a while.
Hope this helps you.
A modem that has more up load and down load channels will give you more stable speeds .
FWIW, even though most, if not all of the newer devices support eight upstream channels, there are only 3 or 4 "upstream" channels currently available everywhere anyway.