An electronic device, the electronic device comprising: a microphone comprising circuitry; a speaker comprising circuitry; and a processor electrically connected to the microphone and the speaker, wherein the processor is configured to, based on a first user's voice being input via the microphone, identify a user who uttered the first user's voice and provide a first response sound obtained by inputting the first user's voice to an artificial intelligence model trained through an artificial intelligence algorithm via the speaker, based on a second user's voice being input via the microphone, identify a user who uttered the second user's voice, based on the user who uttered the first user's voice being the same as the user who uttered the second user's voice, provide a second response sound obtained by reflecting a user's voice including the first user's voice and a response sound including the first response sound as utterance history information by inputting the second user's voice and the utterance history information to the artificial intelligence model via the speaker, based on the user who uttered the first user's voice being different from the user who uttered the second user's voice, obtain a first domain corresponding to the first user's voice and a second domain corresponding to the second user's voice, and based on the first domain being the same as the second domain, provide the second response sound obtained by reflecting the user's voice including the first user's voice and the response sound including the first response sound by inputting the second user's voice and the utterance history information to the artificial intelligence model via the speaker, or based on the first domain being different from the second domain, provide a third response sound obtained by inputting the second user's voice to the artificial intelligence model via the speaker to be distinct from the first response sound, wherein the artificial intelligence model and the artificial intelligence algorithm are stored in the electronic device. a microphone comprising circuitry; a speaker comprising circuitry; and a processor electrically connected to the microphone and the speaker, wherein the processor is configured to, based on a first user's voice being input via the microphone, identify a user who uttered the first user's voice and provide a first response sound obtained by inputting the first user's voice to an artificial intelligence model trained through an artificial intelligence algorithm via the speaker, based on a second user's voice being input via the microphone, identify a user who uttered the second user's voice, based on the user who uttered the first user's voice being the same as the user who uttered the second user's voice, provide a second response sound obtained by reflecting a user's voice including the first user's voice and a response sound including the first response sound as utterance history information by inputting the second user's voice and the utterance history information to the artificial intelligence model via the speaker, based on the user who uttered the first user's voice being different from the user who uttered the second user's voice, obtain a first domain corresponding to the first user's voice and a second domain corresponding to the second user's voice, and based on the first domain being the same as the second domain, provide the second response sound obtained by reflecting the user's voice including the first user's voice and the response sound including the first response sound by inputting the second user's voice and the utterance history information to the artificial intelligence model via the speaker, or based on the first domain being different from the second domain, provide a third response sound obtained by inputting the second user's voice to the artificial intelligence model via the speaker to be distinct from the first response sound, wherein the artificial intelligence model and the artificial intelligence algorithm are stored in the electronic device.