DFT and FFT are essentially the same for the purposes of this question.
To attenuate a frequency bin (or "band") in an FFT-transformed array, you need to multiply both the real and imaginary components by the same factor, and also multiply the real and imaginary components of the corresponding negative frequency bin. FFT produces a transformed pair of arrays where the first half of the values represent positive frequency components and the second half represents negative frequency components.
Here is a simplified code sample for a low-pass filter that explains what I mean:
// fftsize = size of fft window
int halfFFTsize = fftsize / 2;
float lowpassFreq1 = 1000.0;
float lowpassFreq2 = 2000.0;
for (int i = 0; i < halfFFTsize; i++)
{
int ineg = fftsize - 1 - i; // index of neg. freq.
float freq = (float)i * (44100.0F / (float)halfFFTsize);
if (freq >= lowpassFreq2)
{
real[i] = 0;
imag[i] = 0;
real[ineg] = 0;
imag[ineg] = 0;
}
else if (freq >= lowpassFreq1)
{
float mult = 1.0 - ((freq - lowpassFreq1) /
(lowpassFreq2 - lowpassFreq1));
real[i] *= mult;
imag[i] *= mult;
real[ineg] *= mult;
imag[ineg] *= mult;
}
}
Update: after reading your edit, I'd have to say your code is working as expected. I assumed you were getting a massively distorted re-synthesized signal, not a "slighty distorted signal, especially at low frequencies".
I think the distortion you're seeing is the result of the very small window size you're using - this would especially be the case if you're not using a Hanning window approach to reconstruct the original signal.
Try running your code with a more typical window size (like 1024). An 8-band equalizer doesn't usually use an 8-bin FFT window. Typically, the settings of 8 sliders would be used to calculate a curvy function connecting the 8 points in the frequency domain, and this function would then be used to set the bin amplitudes for a much larger, more finely-grained set of frequencies.
One more point, too: the frequency bins divide up the available range evenly, so no matter how big your window size is, more than half of the bins cover frequencies that aren't audible to the human ear. This is why the bands covered by an equalizer are typically scaled logarithmically (e.g. 100Hz, 1Khz and 10Khz for a typical 3-band equalizer) and thus do not apply to equal numbers of frequency bins.
In the case of an evenly-spaced 8 bin window, attenuuation of 5 of the 8 is certain to have no audible effect other than distortion of the audible frequencies.