I had both knees replaced in June and October 2021 and experienced swelling for less than two months afterward. Religiously went through PT after each surgery and all is well today.
Did your surgeon do any testing for allergies to metals? I found out I’m allergic to Nickel. My Surgeon told me if they had implanted the typical joint my body would have rejected it. He said the knee swelling and pain would never go away after surgery and the only fix would have been to remove them. I had Ceramic Titanium double knee replacements that are more expensive, but my only option.
You need to talk to your surgeon. And maybe a different surgeon. But this is pretty common with this kind of thing. Everyone heals at their own pace, some do the rehab religiously and some don't, and a lot of the time orthopedic surgeries just don't work. You need to see docs.