ESP32 Mac Address permanent change

dears, I'm facing a problem that i have my home automation system stopped due to ESP module damage , i have the pin file and i already download it to the new ESP , the problem is i cannot connect from android application and i receive message that the unit is not active , the problem is related to the mac address not inserted to the application data base

I'm searching for method to allow me changing the Mac address permanently with the old Mac address, please your support

No idea what a pin file is.
Each device has a unique MAC; you will need to update some resource it sounds like (poor design)

i think this was done by manufacture as a protection from making copies from device , thats why i need to change the Mac address for ESP

the pin file which i take from another ESP module at another device with same configuration

@mohamed14885 you cant do it permanently you will need to modify the mac every time the device is reset.

News to me. I was taught it is a unique address. Otherwise, the entire internet would fall over. Maybe with an intranet, but no way on the internet.

this is not considered as solution , because this will be programed via IDE and after i will need to download the BIN file from esptool which will clear the program of changing the MAC address

An ESP32 is damaged and so that modules mac is now available to be used as a unique mac on another ESP32 module, no duplicates possible, ever (or at least a lot less likely). A moot point if the OP is unable to add the required code to their binary file. I agree that it is not good practice under normal circumstances but under the circumstances I mention where would be the harm?

@mohamed14885 Agreed. Since it is HA, it is probably on a private network or intranet and does not compete with the MACs of the internet. I guess I missed that part. That means post #5 is the solution so far as the MAC is concerned.
I am beginning to think the OP thinks he can copy the executable code from the damaged esp32 (if it is damaged, you likely can't copy anything)
I have never heard of anyone doing that, but it's a moot point since the device is toast.
As you pointed out, the gotcha is that he needs to run a sketch to change the MAC, but as soon as he tries to install the old copied executable, I will bet a small wager the MAC will revert to factory.
The people who create HA-type systems must provide a way to replace a bad ESP32, and it can be done by a soccer mom. Call the HA provider for support.