You’re asking the wrong question (in two different respects).
First, the question is not whether Windows XP can support another version of Windows but whether your computer hardware can support it.
Second, there’s little point in upgrading to Windows 8 even if you could. Not only was Windows 8 pretty unpopular with most of the users who tried it, but Microsoft will only support Windows 8 for 3 years past the end of support for Windows 7.
Go to the web site of the company that manufactured your computer and see if there are hardware drivers available for versions of Windows past XP. If not, there’s little point in pursuing matters (although it’s possible that a newer version of Windows could be made to work).
You can also download and run the Windows 8 Upgrade Assistant –> http://windows.microsoft.com/en-us/windows-8/upgrade-assistant-download-online-faq
As far as Windows 10 is concerned, if your system could run Windows 8.1, it likely could also run Windows 10, but read this –> http://www.pcworld.com/article/2951112/hardware/can-your-old-pc-run-windows-10-the-answer-will-surprise-you.html and http://www.cnet.com/how-to/what-options-do-windows-xp-and-vista-users-have-in-a-windows-10-world/
If I were you, I’d either buy a new computer or — if your computer manufacturer has drivers for Windows 7 — I’d buy a copy of Windows 7 from Amazon.