Why is count encoding effective in improving accuracy?
Its a good question,
I would just like to add my points
Lets assume you have dataset with features (patient: id,execercise_duration: int, fav_products: category) target(diabetes: Binary) 
Label encoding will just give numbers to every unique category.
Lets assume Category A is ice-cream and Category B is juice and Category C is chocolates.
Now if Category A is encoded 1 and Category B is encoded 2  and Category C is 3 but you keep the encoded feature as numerical series then it would simply mean Category C &gt; Category B &gt; Category A (since 3&gt; 2 &gt; 1). But is it the right information to send to model ?
I guess not.
Intution says people with fav_products as ice-cream and chocoloate will be diabetic.
Category A and B and C just represent three different things nothing is large or small in them.
But if you send frequency or count then lets say more observation in data are of ice-cream, chocoloates and less are of juice. Becuase usually icecream and chocolate are more desirable food than juice. Frequency or count of ice-cream and chocolate will be more than juice.
So keeping frequency or count encoded feature as numerical can give information to model that when this encoded feature value is high outcome is diabetes and when it is low outcome is non-diabetic.
Note: A more complex model like decison tree may be able to give good accuracy even with label encoding atleast for this simple example.