Due to their promising optoelectronic and electronic applications, nitrogen based III-V compound semiconductors (AlN, GaN, InN) and their alloys (InAlN, InGaN, AlGaN) have received a large research interest since the early 90's. In this work, we have investigated the structural behaviour of InN layers and InAlN alloys in InAlN/AlN/GaN and InAlN/GaN heterostructures using complementary techniques: AFM, IBA, HRXRD, Raman and TEM. The study of InN layers has been carried out by HRXRD in order to determine the residual stress and the results were correlated with the morphology as investigated by AFM. The residual stress obtained by HRXRD has been compared with the Raman results, showing that all the layers were characterized by a non pure biaxial stress. The InAlN heterostructures for high electron mobility transistors (HEMTs) are ultra thin layers ranging from a few atomic monolayers to dozens of nanometers. Moreover, their structure can be quite complex in order to optimize the electron gas (2DEG) generated in the transistor channel. We have investigated InAlN layers with In content around 17 % which corresponds to the lattice-match to GaN. In this work, we have shown that it is not easy to control the local composition together with the structure and morphology, meaning that the InAlN layers quality is very sensitive to the growth conditions.