If you buy this you can upgrade the RAM to 6GB if you want and if the motherboard allows it BUT it will be a waste of money because XP 32-bit will only recognize and use around 3.5GB of those 6GBs, so you'll have 2.5GB RAM sitting in your computer that will be useless. You could always install XP Pro x64, which is a 64-bit edition of XP, to get around this problem but I'd recommend that as much as I'd recommend falling down a flight of stairs.
Also, with upgrading the GPU, you may have a struggle because of the case probably not supporting the bigger cards (both length-wise and width-wise - the case looks like a slim tower) and you'd probably also have to upgrade the power supply to run a decent card. These OEM machines also tend to be very "dual-slot card unfriendly" because the motherboards tend to have SATA ports located right underneath where the graphics card would sit. This is fine for single-slot cards, but most of the gaming cards are dual-slot, so the graphics card could cover up the SATA ports if they are located there on the board. It's probably not worth your time or money.
Asides, the Pentium D isn't a great CPU as others have mentioned and for a bit more you can probably pick up something far better with a Core 2 Duo or maybe even a Core 2 Quad if you get lucky.