pdfTeX and XeTeX -- but not LuaTeX -- possess the following feature/bug: The very first word in a (syntactic) paragraph does not get hyphenated. In TeX syntax, a "paragraph" is of fundamental importance. Lots and lots of things are paragraphs to TeX, including the cells in a table that are formatted as a p-type column.
The fix? Either employ Lua(La)TeX or be sure to load the array package and to change p{7mm} to >{\hspace{0pt}}p{7mm}. That way, as far as TeX is concerned, "Borzobohata" (or any other word, for that matter) is no longer the very first "object" in the cell, allowing it to be hyphenated.

% !TEX TS-program = pdflatex
\documentclass{article}
\usepackage{polski} % is it better to use '\usepackage[polish]{babel}'?
\usepackage{array}
\hyphenation{Bor-zo-bo-ha-ta}
\begin{document}
\begin{tabular}{ | >{\hspace{0pt}}p{1sp} }
Borzobohata
\end{tabular}
\end{document}
\\it works ok. Compiling with LuaLaTeX works ok also. It is puzzling, yes. – yannisl Nov 14 '23 at 05:24