DFT of Sinusoid Peaks I am studying DFT of sinusoids, and my professor gave me this signal.

Sinusoid Frequency: 100Hz
Number of Samples: 512
Sampling Rate: 8 kHz

Plotting the spectral plot I have the following:

I was expecting a single peak initially since the signal is only composed of a single frequency but from my understanding of the DFT, it mirrors the positive and negative values from the Nyquist rate which is 4kHz hence resulting to the two peaks. My professor then asks to 'correct' the peaks by modifying the parameters of the sinusoid. I am just confused as from what I understand the resulting peaks are correct.
What you understand is right. The second peak is the negative frequency component. I guess what your professor meant is that the Fourier transform of a sine wave is theoretically perfect Dirac $\delta$ function, and the discrete Fourier transform of a sine wave is a Kronecker $\delta$ function, but in your implementation, it's two peaks instead of two $\delta$ impulse.
The problem is the relationship of the frequency of sine wave and FFT size. As we know the frequency resolution of FFT is
$$
\Delta f = \frac{f_s}{N}
$$
where $f_s$ is sampling rate and $N$ is the length of FFT.
The FFT results in perfect $\delta$ only when the sinusoid frequency is exactly integer multiples of $\Delta f$.
In your case $\Delta f=15.625$ Hz, try something like 125 Hz and see what happens.