What do you mean "what is xampp doing and how it's doing it?".
xampp stands for [cross-server] apache, mysql, php and perl.
Apache is your web server. it runs on the server at all times, listening for traffic coming in on port 80 (standard http port) and 443 if applicable (standard ssl port). You basically tell Apache where your files are located and it serves them up to the users that request them. This is just for static content, though, for dynamic sites you need something like PHP.
When you implement PHP, you are telling Apache to have PHP execute your scripts and generate content dynamically, usually because you want to fetch information from the database, which is where MySQL comes in. MySQL lets you store and retrieve data, in the case of Drupal it's storing your custom content.
Perl is more of a scripting language. Not sure how Drupal utilizes it (assuming it does).