You can't place tiles over other tiles in one tilemap. Each tile can only be placed on each cell. Your image is completely fine, that's a normal behavior.
Make each "wall" as a separate tilemap object or draw your tiles differently to accommodate all possible solutions - like part of the wall overlapping different part of the wall.