There are a lot of factors in the exhaust sound of an engine, including pipe diameter and length, the muffler used, catalytic converters, valve size and orientation, cylinder bore diameter, etc., but the main thing that gives any engine its signature sound is the spacing of the exhaust pulses, which is determined by the location of the cylinders and the firing order. The reason for V8s having that signature sound is because of the cross plane design of the crankshaft, which means that if you look at each bank of the engine separately, the power stroke of each piston will not be evenly spaced out. As a result of this, the exhaust pulses are also uneven, so it creates a fluttering of pressure in the exhaust, that you hear as the signature V8 rumble. A typical 4-cylinder engine has what is called a flat plane crank, which means when 2 cylinders are at the top of their stroke (one on compression and the other on exhaust), the other 2 are at the bottom (one finishing the intake stroke and the other the power stroke), so there is an evenly spaced out sequence of exhaust pulses every 90 degrees, which produces a higher pitch humming type sound, which is characteristic of inline 4-cylinder engines. That is what produces the different sounds of typical 4-cylinders and typical V8s. It should be mentioned though that there have been some flat plane V8s made, which actually sound like 4-cylinders, as well as some cross plane 4 cylinders, which actually sound like V8s, but both a flat plane V8 and a cross plane I4 create unwanted vibrations, especially in larger displacements, so to my knowlege nobody is still manufacturing a flat plane V8, and I believe cross plane 4 cylinders have only been made for motorcycles, not cars. Also, some race cars and supercars have V8 engines with 180 degree headers, which connect each exhaust port with the piston that is 180 crankshaft degrees away from it. The reason for this is to improve exhaust scavenging, and it works quite well, but it has 2 downsides. First, it is a PITA to package because you need multiple header tubes to cross from one bank over to join with the other, and secondly, it will make the V8 sound like a large 4 cylinder.
When it comes to 6-cylinders, straight sixes give you some room to work with the sound where V6s don't. Most straight sixes use a tri-y type setup where you have 2 headers, each with 3 cylinders manifolded together, and then those to headers y together further down the exhaust. When all the cylinders are in a line, it is pretty easy to mix and match which cylinders are paired together, and that makes a huge difference in the sound. All straight sixes have a firing order of 153624. The simplest manifolding would be pairing 123, and then 456, however if you do this, as far as the exhaust goes, you have effectively created 2 separate 3 cylinder engines running simultaneously (because each of the front 3 cylinders fires 120 degrees apart just like a 3-cylinder, and each or the rear three fire 120 degrees apart), and as a result, it will sound like a 3 cylinder engine, and will buzz and whine worse than the a 4" exhaust on a honda civic. The solution is to move one of the primary tubes, which creates an uneven exhaust pulse, which is similar to what causes the V8 rumble. That is why if you look at the manifold of a straight six in a BMW, Mercedes, Jaguar, Supra, or pretty much any performance oriented straight six, they run the pipe from cylinder 4 in with 1&2, and the pipe from cylinder 3 in with 5&6. This will not make it sound like a V8 because with 2 fewer cylinders, no matter what you do, the exhaust pulses are going to be space apart differently, but it does eliminate that can of bees sound. In a V6, you have to work with the way the firing order is, and what cylinders are on what bank. The GM 60 degree V6 is actually known for having a good sounding exhaust due to the firing order of 123456, and thanks to GMs cylinder numbering, cylinders 123 are paired together, as are 456, so you have a very uneven exhaust pulse, which translates to horrible exhaust scavenging, but a nice rumbling sound.
Now we get to our beloved ford 3.8. The firing order of the 3.8 is 142536. Ford numbers their cylinders in straight lines so that on one bank you have cylinders 123, and the other bank is cylinders 456. First cylinder 1 fires on the passenger side bank, then 60 degrees later, cylinder 4 on the driver's side. Next cylinder 2 fires 60 degrees after that, which is 120 degrees away from cylinder 1. Next comes 5, which is 120 degrees away from 4, then 3 which is 120 from 2, then 6, which is 120 away from 5. So on each bank of cylinders that are paired together on a 3.8, you have one cylinder firing every 120 degrees, so on a Ford 3.8 V6, if you look at each bank separately, it is effectively its own 3 cylinder engine, so when you hear the exhaust on a Ford 3.8, you are hearing 2 inline 3-cylinders running simultaneously, and that is why they have a tendency to buzz and hum and whine and generally sound like a Honda with a fart can. My advice if you want a 3.8 to sound decent is to try to keep it quiet. It will never rumble like a V8, and if you run too large a pipe, or too loud a muffler, or delete the resonator or the cats, it is all too easy to make it sound horrible.