There are several different kinds of capacitive sensing. But in general, they all work by using an array of sensors to monitor the electrostatic field around the screen. When your finger touches the screen, it changes the electrical capacitance of that portion of the screen. This is detected as a change in voltage at various locations. The microprocessor captures, filters, and analyzes the data. Then it calculates the coordinates of where the touch occurred. You can read more about capacitive sensing here: http://en.wikipedia.org/wiki/Capacitive_sensing
When a stylus is used, the same principles apply. The only difference is that the stylus is acting as a conductor to transmit electrical charge between your hand and the phone. In order to function properly, a capacitive stylus must meet several criteria.
1. A conductive surface: It must be able conduct an electrical charge between your hand and the screen. If the material is too resistive or if the distance between your hand and the screen is too great, the signal reaching the screen may be too weak to be detected.
2. At least 1/4 inch wide: When filtering data, the processor ignores areas that are significantly smaller than a human finger tip. This helps avoid unintentional activation. Having a stylus that is about 1/4 inch wide will ensure that there is enough surface area to be detected.
3. A relatively flat end: Having a flat tip ensures that the whole face can get close enough to the screen to be detected.
4. A smooth surface: This will ensure that you don't scratch up your screen.
Following these criteria, you can find a wide variety of common items that can be used to activate a capacitive touch screen. Here are five of my favorite designs for a DIY capacitive stylus.