negative (white stripes) side of diode goes to positive of motor. The other goes to negative. Purpose is to protect your ESC from backflow current during braking.
If power caps the one you're talking about, just hook positive to positive of your batt (or positive of ESC in that sense) and similar to the negative. Value of cap depends on motor, effect you want to get. Better info, search online, sure bound to found one.