Dukes and duchesses ruled areas called "duchies". These duchies were rarely their own countries, and usually parts of a larger sovereign country ruled by a king and queen. So there would be one king and one queen ruling a country, for example, but there could be several dukes and duchesses ruling smaller territories of the country. Dukes and duchesses are always lower than kings and queens.
Barons and baronesses are the lowest ranking of the nobles. I'm not certain what power they had but I'm pretty sure the title was mostly honorary.
A basic hierarchy would look something like this:
Emperor/Empress
King/Queen
Archduke
Grand Duke
Prince/Princess
Duke/Duchess
Marquess/Marchioness
Earl
Baron/Baroness
I'm pretty sure I left a few titles out, but hopefully that answered your question.
A duke is the member of nobility that ranks just below the monarch. A duke is a ruler of a 'duchy' (county, territory or domain). It's also tradition for men of the royal family to get a new title when they marry - often taking on duke status.
A duchess is the wife or widow of a duke, or a woman who equal holds the rank of duke in her own right. Baron is a rank of nobility or title of honor, often hereditary. The female equivalent is baroness.
A baron is a member of the lowest order of the British nobility. A baron is a nobleman — a member of the aristocracy. Barons are also important, powerful businessmen with huge influence over their industries.