Yeah. "On foot" might be more common, but if you were asked if you came by bus or by train you might, if you had walked, say "by foot."