You'll need to use some plugins. I don't believe you can get this numbers on all devices, there may be security limitations on later versions of Android, non-SIM phones do not have IMEI numbers, and I believe iOS devices (and perhaps Windows) devices won't share that info with your app.
Search for "cordova plugin read imei" to find some plugins.
Go to the plugins tab and add intel.xdk.device plugin. When you are done, use intel.xdk.device.uuid to get the IMEI on Android. It works on 2.3+. I have also tried it on 5.1.1