Attaching workflow to node using rule
Why not just set up a workflow that includes a default "no_workflow" state?  Use rules to automatically set all nodes to the "no_workflow" state upon creation.  Then, when a node is flagged, use rules to set it to the appropriate state.  That way, all nodes are subject to the workflow, but by default they don't move through the states until they are flagged.