Usually figures are placed where there is enough space, e.g. for begin{figure}[ht]
at the beginning of the next page. Sometimes, some or all figures are placed at the end of the document. What if you want to place the figure within your text, because you have other figures which you do not want to place only at the beginning of the second next page…
There is a little trick, which helps to place figures where you want them. Use an exclamation mark after h:
\begin{figure}[h!b] ... \end{figure}
When there is enough space on that page, by relaxing some constraints.
Try [H] for if [h!] didn’t help:
\begin{figure}[Hb] ... \end{figure}
If you have a really big figure, try reducing its size if possible.
The exclamation mark, [h!] and [H] give you more control on figures placement in the text.
It works the same way for tables.