The density is the number of pixels per inch.
You could have two different devices with the same resolution for example 640*960 pixels but with different physical sizes, a 3.5'' and a 7'' screen.
The device with the 3.5'' screen has a density of 320 pixels/inch
and the tablet with the 7'' screen has a density of 160 pixels/inch.
If you design one layout file for both you will get all views shown proportional to the physical screen size, a same button will have its physical width and hight double on the 7'' screen than on the 3.5'' screen.
In case above I would make two different layout files because the big physical difference. You can put much more views, with a same physical dimensions, on a 7'' tablet screen than on a 3.5'' screen with the higher density.
So one layout file with 640*960 density 320 for the 3.5'' screen
and a second one withe 640*960 density 160 for the 7'' screen.
Best regards.