It's not that easy, unfortunately. The problem lies in the relationship between a mind - the system of patterns of connections and processes that constitute whatever it is that allows a subjective experience to occur as an emergent property - and the external world. That singleton which has experience, and the infinite outside which it experiences.
Free will could be framed as unpredictable behavior arising from the emergent system itself, where the selection of one choice among many is deterministic, but otherwise indistinguishable from a non-deterministic system to any other mind. This is a plausible scenario that aligns with chaos theory and implies that every mind is a unique occurrence.
The firing of a single neuron can be triggered by quantum circumstances affecting the location and energy of a single calcium ion, and that single neuron can be responsible for radically different states in the meta-patterns that comprise a mind at any given point in time. Even software on silicon could be subject to bitrot, cosmic bit flips, and other fundamentally unpredictable changes. How such randomness affects the system plays into whether free will can exist in this sense.
The idea behind free will is that the mind has the ability to make choices independent of any influence except itself. It's highly probable that minds are entirely abstract, dependent on the physics of its substrate but existing as an emergent result of the particular arrangement of particles and energy in the substrate. If the choices made by a mind are indistinguishable from a hypothetically independent system not dependent on the physics of the substrate, it could be seen as "free will." Is definitely not the religious/supernatural Free Will, though.
If a mind is perfectly replicable - if you can perfectly simulate the state and ongoing experience of the mind bit for bit, - then you should be able to perfectly predict its behavior and state over time. It could be that such replication is mathematically possible but fundamentally intractable. Such a result would mean minds exhibit behavior indistinguishable from free will. It would mean that perfect knowledge of the state of the mind could never be known outside the mind itself - an extension of Heisenberg uncertainty - and simulations would be inaccurate.
The emergent, entirely abstract meta-system comprising the mind and its subjective experience could also be seen as the non-physical soul or spirit. That doesn't make room for the supernatural or magic in the universe. It might mean that divergence from prediction by the outside exists but is vanishingly small. It could also imply high probability of divergence if compute capacity needed for simulation grows exponentially over time and capacity of the mind being simulated. The answers will depend on exactly whatever "minds" turn out to be and the mathematics that govern the phenomena.
I personally think that radical divergence is likely, for no better reason than to think the universe is a much more interesting and weird place should that be true. It would mean that minds will forever be surprising, however much we increase computation and efficiency.