I'd rather a dog as they love you back, you can take them for walks and play with them. With guinea pigs , they eat loads. Poo loads and just sit on your knee!
Having said that I have three piggies! But as an adult I enjoy just watching them go about there piggy lives, I don't think a child would get much from them as they don't really interact with you. I have a 3 year old son who does like feeding them, stroking them occasionally but that's it really. My 7 year old sil loves them as they look cute, and her and her mum have looked after them while we were away. Her mum said her daughter enjoyed them to cuddle but they don't really do much.
They are a lot of work with cleaning them out. We keep them in a 2 storey hutch in the summer, with a metal run and another wooden box attached. So them have grass and loads of space to roam. They have a layer of newspaper, wood shavings, hay. In the upstairs sleeping bit, they have newspaper, 'vetbed' with fleece on top. We have three females, 2 are 4 years old and 1 is 3 1/2 years old. They get on we'll but I don't think they really love each other, having their own space is important, so lots of hiding places- cardboard boxes/ big tunnels. We have short haired piggies which just need a bath when they get abit dirty and a brush once a week.
In the winter, they come in the kitchen. We have a large ground floor level cage, I fill in with woodshavings and hay generally, but I have used layers of towels and fleece on top which they love. Have a google and lots of options on bedding will come up on other forums.
One thing to consider is if you have enough space for them.
One of mine has tumours , she was diagnosed two years ago but is still going, but she does need extra care ie. salt bathing.
They need fresh Veges, but check out which foods are poisonous!