Windows 98 CD keys will get you no where. That would not validate windows. You require to get a full new version of XP and then install it on the computer afresh. However a PC running 98 may be very very slow running XP as it eats ram. 512mb is just about tolerable 256 or less and you will not be having a lot of fun.
From what I read it appears you are under the impression XP is an upgrade. However this is not the case. XP is a completely new piece of software.