Try this
$countries = Cuntry::query();
// Search
if (!empty($this->term)&& $this->term != null)
{
$countries = $countries->search(trim($this->term));
}
// * Trashed
if ($this->trashed){
$countries = $countries->onlyTrashed();
}else{
$countries = $countries->withCount('city');
$countries = $countries->withCount('employ');
$countries = $countries->where('column name', 'Male')->count();
Like this second one do replace male with female
Male ?????
Female ????
}