I'm unaware of any canon reason the TARDIS chose to land in the Junkyard in the first episode of Doctor Who. Presumably it was simply chosen as a location that was sufficiently anonymous but still afforded the Doctor the ability to have a listed address.
Regarding the reason it's a policebox (as opposed to another shape) according to the minisode "Meanwhile in the TARDIS", the 'chameleon circuit' is intended to provide the ship with an adequate disguise by;
"within the first nanosecond of landing its chameleon circuit analysed
the surrounding area, calculated a twelve-dimensional data map of all
objects within a thousand-mile radius and then determined which outer
shell would best blend in with the environment."
It's worth pointing out that a thousand mile radius would take in the whole of the UK and most of Europe (as well as a large area of sea) and not just the immediate surroundings of the junkyard although I think we can assume the TARDIS would be smart enough to prioritise the more immediate surroundings and recognise that it's on land.