Okay, I'm going to ago into a little detail here, but I'll try to keep it simple.
First, we need to talk about light, electrons and color. The visible light we see around us is not the only light there is. Overall, any and all "light" is just a kind of electromagnetic radiation. Electromagnetic radiation is a very very weird and complicated thing. We can talk about it as if it is waves moving through empty space, which seems odd. Waves are usually thought of as moving matter, right? Like a wave in the ocean is made of moving water. A sound wave is made of vibrations moving through matter. It seems counter-intuitive to have a wave that isn't made of moving matter, but that is still what electromagnetic radiation is. Almost. Kinda. It is also made of single (mass-less) particles moving through space called photons.
What does this have to do with electrons? This part is actually pretty simple. Electromagnetic radiation/photons are the "force carrier" that transfers force to and from electrons. When an electron absorbs EM radiation/photons, it moves away from the nucleus of the atom it is "attached" to. (This means that it has gained potential energy, just as though moving an object up off the Earth's surface increases the potential energy. In either case, the forces of electromagnetism or gravity will "want" to pull the object back. The larger the distance for it to move back through, the more potential there is for energy.) When an electron moves back towards a nucleus, it loses energy and gives off a photon.
As for color...well, the particular wavelength of the EM radiation (or energy of the photon) affects the color we see. When we look at the sun, we see a white color. (Please do not go check this by staring at the sun. Yes, the sun will look yellowish around the edges in particular kinds of weather, and kids tend to draw the sun as yellow, but the sun is actually radiating what we think of as white light.) That "white" light is actually the entire visible electromagnetic spectrum: red, orange, yellow, blue, green, indigo, and violet. To see that this is true, all you need is a glass prism that can split the light up into individual colors...or water droplets to do the same thing in the sky, making a rainbow. In any case, the color we see depends on the wavelength or energy of the EM radiation/photons.
So, now we need to bring all this together to explore what happens when light hits normal everyday objects. When "white" EM radiation (we'll avoid talking about the effects of colored light) hits an object, what happens depends on the structure of the molecules that the substance is made of. You see, the electrons in an atom or molecule can only "live" in certain places, at very specific distances from the various nuclei of the atoms that make up that molecule. When EM radiation/photons "hit" those electrons in the molecule, there are really two options. The first one is that there are electrons in the molecule that could jump to a new position if they absorb the exact amount of energy needed. In that case, parts of the EM radiation wave/some of the photons will get absorbed and disappear. In this case, as the electrons move away from the nuclei in the molecules, the molecules literally expand kinda like a balloon. As they press into the molecules around them as they expand, they start vibrating and jiggling faster, increasing the temperature and heat energy of the substance. The second one is that there aren't electrons that have a place to move to that will allow them to absorb the EM radiation/photons. In the second case, the EM radiation can either get reflected back or pass on through.
So, what does this really look like? Well, white light hits an object. Some of the waves/photons in that light get absorbed and turned into heat energy as electrons move and bounce around. The colors associated with those waves/photons are absorbed. They are gone. The remaining waves/photons are reflected back. THOSE remaining waves/photons are the colors we see when we look at the object. For example:
White light hits an object. That object has electrons that can absorb the wavelengths/photon energies associated with red, orange, yellow, indigo, and violet. The energy of those colors has gone into heating up the object or substance. The remaining colors of blue and green get reflected back, so when we look at it, we see a bluish-green color.
Now we can see what is happening with something black. When white light hits a black object, there are electrons in the molecules that make up that object that can absorb all the waves/photons/colors contained in the white light. All the colors/waves/photons of red, orange, yellow, blue, green, indigo, and violet get absorbed by electrons, which then change positions and cause the temperature to rise. No visible light gets reflected back, so we see the absence of visible light: blackness.
To sum up, black substances have the electrons in the right places to absorb all EM radiation. Everything absorbed gets converted into heat energy. And that is why black objects "absorb" more sunlight and get hotter. The moral of the story? If you want to stay cool on a sunny day, where white colors that will reflect most of the light back without converting it into heat energy.