To check if a Path exists to a directory, use this one:
$pathToDirectory = "c:\program files\blahblah\"
if (![System.IO.Directory]::Exists($pathToDirectory))
{
mkdir $path1
}
To check if a Path to a file exists use what @Mathias suggested:
[System.IO.File]::Exists($pathToAFile)