I've heard from a few friends who do portraits, weddings, etc. that most of the "photo magic" is really just handled in Photoshop, and how the camera is actually used, and the camera is not the only thing to think about.
While slight processing of an image is needed to correct white balance, colours, exposure, etc. I would slightly disagree that most of the "photo magic" is in Photoshop.
But I do agree that the camera is not the only thing to think about. Far more important than the camera are the lens and lighting.
Nikon D3000 has about 10 megapixels. Plenty for portraits if you frame the picture to take advantage of all of those pixels, although as of 2019 even entry-level cameras offer more. It has 11 focus points, which might limit you more than its 10 megapixels. As a DSLR, it lacks eye autofocus. Its flash sync speed is 1/200 s.
If looking for a entry-level portrait camera today (2019), I would recommend some entry-level mirrorless camera because they have a high number of AF points + eye AF, and because they do focusing using the main imaging sensor so they pratically guarantee accurate and consistent focus even with third party lenses.
To take good portrait pictures with a crop sensor camera, I would recommend adding at least 50mm f/1.8 lens (they are good value for money), perhaps a 85mm f/1.8 lens, at least a flash or two with suitable flash stands and light modifiers like umbrellas, and some means to remotely trigger those flashes. If taking photographs in sunlight using a flash, add a 4-stop ND filter because of the 1/200 s flash sync speed (sunlight + flash + wide-open aperture requires either an ND filter or a higher shutter speed; the latter means high-speed sync which "wastes" part of the power output of the flash).
If using a full frame camera, select the 85mm lens but consider replacing the 50mm lens with a 135mm lens if you can afford it. Of course this is not to say that 50mm is particularly bad for portraits on full frame; it just requires short working distance to fill the frame, and at a short distance it slightly distorts the face. However, if you instead of emphasizing the subject want to put the subject into context with the environment, 50mm could be a good option with full frame.
Is there a flash or some other add-on I should purchase that will help the camera? I just have the onboard one now.
Yes, an external flash is very useful (and two external flashes is better than one). Don't use the onboard flash! It is so close to the lens that reflections from the blood vessels in eye result in red eyes. With an external flash, even mounted on-camera, you won't get red eyes (at least at short distance; I haven't tested with max power + long distance mounted on the camera). Also, the built-in flash does not work with large diameter physically long lenses, because the lens casts a shadow. It's intended mainly for the kit lens.
If the room where portraits are taken has a low and white ceiling, an option to make the flash less harsh is to bounce it from the ceiling. It requires a flash with a tilting head. But, a far better option is to use it off-camera, trigger it remotely, and use umbrella light modifiers.
When selecting a flash, consider its compatibility with your camera's through-the-lens metering, its ability to be triggered remotely, and prefer flashes that have a fully tilting head that can be tilted to all directions. Even when used off-camera, if shooting outdoors, you may need the ability to tilt the remote trigger sensor towards the camera. Radio triggers of course don't have this restriction. In sunlight, you might want to consider the power of the flash too, but in any other circumstances the power probably won't be limiting you.