Ok looks like the directory used earlier did not have the ondemand.xsd file.
After the location from where arsxml was run was changed to D:\CMOD\SERVER\bin\xml, it worked because that the default location where ondemand.xsd is placed after installation.
To run the arsxml command, you should have the ondemand.xsd int he directory from where you run the command.