As babies they could easily escape a guinea pig cage. As adults it would be unlikely.
On average as adults a female rat will weigh 350g-550g
Male rats 500g-900g
depending on build - give or take - that's just a rough guide. Breeder rats tend to be much bigger than pet shop/rescue rats.
Rats need a good width - about the same as hamsters really, nothing less than 80cm, preferably 1 metre + - but much more height, which is where a guinea pig cage can be a let down.
Rats are addictive though! As you can introduce new rats to existing rats (certain methods that need to be done to get it right as introductions can be tricky) - it can be hard to resist getting more....so getting the biggest cage possible will prevent you having to upgrade later when you can't resist adding another couple of faces
You need to decide whether males or females are for you! As babies they are all pretty much the same but when they get to about 1 year old you start to see differences between the sexes.
Personally, having had both and all my girls were typical females, I did prefer the boys. Boys are stinkier though! But I kinda loved the smell, they smell like biscuits and fake tan! haha. But it's a very individual choice, a good friend of mine had both sexes and really preferred females. I found the lads to be a lot more laid back, enjoying belly kisses and that sort of thing, whereas the girls were having none of that.
Here's a video of my set up when I had 9 rats
https://www.youtube.com/watch?v=s_dB_H-op7w
This is an adventure playground I built using C&C grids:
https://www.youtube.com/watch?v=SBPVaxd-SHE
And my favourite video that always makes me cry - pea fishing with Tinkerbell and all the old group, including my heart rat, Benji. They've all passed away now - it breaks my heart
https://www.youtube.com/watch?v=qf75Y9B3ryo&t=1s