This is a very interesting question, with a very complicated answer!
The problem of Aero-Elasticity is not easy or simple to solve. The reason is, that the equations (or better the system of equations) which describe it are not simple (in this case the non-linearity of the aerodynamic forces create most of the analytical problems). Flutter can be assessed with an aero-elastic simulation.
The following graphic (from EPFL) illustrates the system of equations.
As you can see there are roughly speaking three things (and their interaction) a designer needs to keep in mind: Dynamics, Fluid-Mechanics, and Structural Mechanics. Usually this is done using simplified versions of the airplane like the following (taken from DLR).
Based on this simplified representations of the air-plane trade-studies can be done to collect a better understanding.
The TL;DR answer to your question is: Yes, all the things you mentioned need to be taken into account to design an air-frame.
When designing an airplane the position of the engine does matter. But it is not only the position but also the mass and the elastic properties of the air-frame. On top of this the aerodynamic forces need to be taken into account as well.
There are no simple recipes to reduce flutter because most of them only work for a limited set of boundary conditions.
A very (vague) basic one could be: Place engines so that manoeuvre loads will result in a small (as small as possible) elastic deformation (thereby reducing the amount of potential energy which is stored in the airframe).
The other recipe is to look what others have done. Given you are planing to use the aeroplane in a similar way other manufacturers offer aeroplanes and given you are using similar materials and manufacturing techniques: you could use existing designs as starting points for your trade-study.