Your questions suggest a bit of confusion between memory and swap; I'll try to explain.
swap is used as a holding area for RAM. When memory gets low, RAM which hasn't been used recently gets copied into swap space then recycled, given to something else. When something tries to use memory which has been copied into swap, it's forced to wait for it to be read back out of storage.
You don't allocate memory versus swap -- it's the same thing as far as a userspace program's concerned. Traditionally, any memory is backed by its own area of swap anyway. It doesn't get used unless needed, but it's there. So you'd want to have at least as much swap as RAM, and potentially more.
This makes it possible to use more memory than you have RAM, by copying excess things into swap so it can make up the difference. This has a significant performance cost, because swap space on disk is much slower than RAM.
vivex-goel-piet runs Solaris 9 (according to another post). All my links to the very old online manuals don't work any more since Oracle revamped the website. He could of course type "man swap" and post the bit of the manual he doesn't understand.
If the above were true, why does my swap memory increase in size which means something less used from the RAM was transfered to the swap memory even when the process I am starting is -xms=512M and -xmx=512M and the Total current free RAM is 4 GB.
It should ideally allocate 512M from the free 4GB of RAM rather than freeing up space on the RAM inorder to accomodate 512M process.
Yes. Whether it does or does not depends on all sorts of factors.
No.
Your questions indicate that you have little understanding of how virtual memory works on Unix/Linux or how memory management works in JVM. I recommend that you spend so time researching the subjects.