Here are a some hobby tips for achieving that goal.
One simple way of making units look the same yet different is to paint the same uniform colors on all the models, but distinguish them through squad markings. In the photo below you can see seven different squad markings on the pauldrons (shoulder pads) of the Deathwing Terminators.
Notice that some of the designs are sculpted on the pads while others are flat hand painting on a smooth surface. One of them is even a decal. Designs that are hand painted are deliberately kept simple so that they are easy to reproduce repeatedly on many models.
Another method is to paint the same symbol or use the same picture decal with color coding by squad. In other words, you could have multiple squads with the same picture on their designated squad marking area, but make each squad's badge a different color. For example, if one squad has a picture of a grey skull on their pauldrons, another squad might have a red skull and yet another might have a blue one.
As you can see, the two pictures below are identical except for the color. In this case color coding makes it easy to identify squad members at a glance while the badge itself provides uniformity between units in the same army.
Of course, different squad types can have identical or nearly identical squad or army markings, but their equipment makes them obviously different squads. In the two photos below the Chaos Chosen and the Chaos Space Marine Warp Talons have the same markings on their pauldrons, but their equipment and other accouterments make it clear they are in different squads.
The Chosen have off-white helmets and red tabards to set them apart from other squads in the army including those with similar shoulder markings. Of course, another obvious difference between these two squads is the basing.
The star pattern on each shoulder pad on both the Chosen and the Warp Talons is a bit complex and not exactly identical on any two models. The star pattern design and colors tie the models together as part of the same army, but the exact placement of stars and color pattern on each shoulder pad varies from model to model. In this example the squad markings themselves are alike yet different.
In my Ork army the regular Boyz have a single plain steel shoulder pad (first photo below) while the 'Ardboyz all have two pauldrons with checker patterns on one and a black-red split on the other (second photo below). This makes the 'Ardboyz easy to identify visually from the massive number of ordinary Boyz in the army. All of the Nobz in the army have adornments like checks to set them apart from "da Boyz".
There are other options as well. For example, Games Workshop's Cadian Imperial Guard models come with number decals one could use to differentiate squad membership amongst models with identically colored uniforms.
The method of providing units with unique markings can be inspired by traditional methods of identifying military units or they can come straight out of your own imagination. There are many books about uniforms and modeling manuals to help you along the way and as you probably already know Games Workshop provides many helpful painting guides as part of the background lore they've included in many of their Codex and Army Books.
Warhammer and Warhammer 40,000 are fantasy games, so there's really no correct or incorrect way of marking your units. One can follow GW's suggestions or follow one's own heart. Be creative and have fun with it.
Coming up with ways to make each unit in an army look like part of the whole yet have it's own distinctiveness can be quite a challenge, especially in an army with lots of models and units. Part of the fun with this task for me is to let the type of army help dictate what kind of squad markings I use. My Cadian army squads have numbers or simple uniform badges while I tend to get more creative with armies like Eldar, Orks or Chaos. Each army has its own character and sensibilities and these can help you decide what system of markings to use or whether or not its worth using one at all.