The Cowboy Hat is an armor item sold by Bratty and Catty. Its offensive counterpart is the Empty Gun.
It appears to have belonged to the human of the yellow SOUL before their death, along with the Empty Gun. According to Bratty and Catty, these items were found in the garbage dump at Waterfall, hinting that a human may have been present in this area before, or lost this item where it eventually worked its way there in other ways.