So, what do we need to create a Debian installer?
I have found two important explanations on how we can make it possible. Lets have a look at
http://www.ibm.com/developerworks/linux/library/l-debpkg/index.html
The following also helped me(it seems to be quite old article though)
http://tldp.org/HOWTO/html_single/Debian-Binary-Package-Building-HOWTO/
We need the following two packages
build-essentials (it is already intalled in most of the linux systems)
dpkg-dev
We use the following commands to create the package:
dpkg -b directory package.deb
There is a good tool called lentian, we can install it to find out the problem. It is a like required tool while creating the debian installer.
The above mentioned links are quite informative.