Picture a decision tree drawn on paper. The first question splits the page into two branches, and on one branch a follow-up question splits it again. A cinema check works that way: if you have a ticket, then if you are old enough for the film you go in, else you are told the film's age rating; and if you have no ticket at all, you are sent to the box office. The age question sits inside the ticket branch, so nobody without a ticket is ever asked it.
Indentation shows where each question lives. In Python the inner if is indented one level deeper than the outer one, and each else lines up with the if it belongs to. Trace one person at a time: ticket = True, age = 10, film rated 12. The outer test passes, the inner test 10 >= 12 fails, so the inner else runs and prints the rating message. Every combination of inputs follows exactly one path and gets exactly one message.
Not every pair of checks needs nesting. If an action needs two facts and nothing else happens when only one is true, if has_ticket and age >= 12 does the job in one line. Nesting earns its place when the branches do different things, like sending the ticketless person to the box office and the too-young person away with a different message. A chain of if, elif, elif is different again: it sorts one value into bands, such as grades A to F, rather than asking a follow-up question.
Think of it like this. Asking for directions inside a big building is a nested decision: is it on this floor? If yes, is it left or right of the elevator? If no, take the stairs and ask again upstairs. You only ask 'left or right' after the first answer is yes, just as an inner if runs only after its outer test passes.
Core idea. Nesting adds precision to decisions but increases complexity. More than 3 levels deep is usually a sign to restructure your logic.